在Meteor中不能使用aws-sdk

出于某种原因,我似乎无法让AWS SDK在Meteor 0.7.0.1中工作。 如果我使用npm安装,我得到以下内容:

While building the application: node_modules/aws-sdk/node_modules/xml2js/node_modules/sax/examples/test.html:1: Can't set DOCTYPE here. (Meteor sets <!DOCTYPE html> for you) node_modules/aws-sdk/node_modules/xml2js/node_modules/sax/LICENSE-W3C.html:1: Can't set DOCTYPE here. (Meteor sets <!DOCTYPE html> for you) node_modules/aws-sdk/dist/console.html:1: Can't set DOCTYPE here. (Meteor sets <!DOCTYPE html> for you) node_modules/aws-sdk/dist/s3upload.html:1: Can't set DOCTYPE here. (Meteor sets <!DOCTYPE html> for you) node_modules/aws-sdk/dist/tests.html:1: Can't set DOCTYPE here. (Meteor sets <!DOCTYPE html> for you) node_modules/aws-sdk/dist-tools/browser-builder.js:1:15: Unexpected token ILLEGAL 

如果我全球安装(-g标志),我得到:

 Error: Cannot find module 'aws-sdk' 

我也尝试安装meteor-aws-sdk和aws-sdk-npm,这两者似乎都不工作…目前我正在尝试使用该行:

 Npm.require( 'aws-sdk' ); 

导入模块。

你已经使用npm安装了模块。 meteor不支持这种方式安装npm模块。 你需要在大气层上使用诸如npm包等包装。

你可以使用陨石安装aws-sdk 。 有一个最新的包装的气氛: https : //atmosphere.meteor.com/package/aws-sdk