ng-annotate似乎无法在其node_modules目录中找到

时间:2015-03-10 21:41:29

标签: angularjs gruntjs npm

当我运行grunt ng-annotate时,我会收到以下错误:

$ grunt ng-annotate
Loading "ng-annotate.js" tasks...ERROR
>> Error: Cannot find module 'ordered-ast-traverse'
Warning: Task "ng-annotate" not found. Use --force to continue.
Aborted due to warnings.

所以我检查了ng-annotate的目录,并且有足够的证据证明有序 - ast-traverse就在那里 - 在node_modules/目录中,不能少!

# from project root:
$ grep -r ordered-ast-traverse
node_modules/ng-annotate/ng-annotate-main.js:const traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/node_modules/ordered-ast-traverse/ordered-ast-traverse.js:// ordered-ast-traverse.js
node_modules/ng-annotate/node_modules/ordered-ast-traverse/README.md:# ordered-ast-traverse.js
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "name": "ordered-ast-traverse",
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "main": "ordered-ast-traverse.js",
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:    "url": "https://github.com/olov/ordered-ast-traverse.git"
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "readme": [...truncated...]
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:    "url": "https://github.com/olov/ordered-ast-traverse/issues"
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "_id": "ordered-ast-traverse@1.1.1",
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "_from": "ordered-ast-traverse@~1.1.1",
node_modules/ng-annotate/node_modules/ordered-ast-traverse/package.json:  "_resolved": "https://registry.npmjs.org/ordered-ast-traverse/-/ordered-ast-traverse-1.1.1.tgz"
node_modules/ng-annotate/scopetools.js:const traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/lut.js:const traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/build/es5/ng-annotate-main.js:var traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/build/es5/scopetools.js:var traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/build/es5/lut.js:var traverse = require("ordered-ast-traverse");
node_modules/ng-annotate/package.json:    "ordered-ast-traverse": "~1.1.1",
node_modules/grunt-ng-annotate/node_modules/ng-annotate/ng-annotate-main.js:const traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/scopetools.js:const traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/lut.js:const traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/build/es5/ng-annotate-main.js:var traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/build/es5/scopetools.js:var traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/build/es5/lut.js:var traverse = require("ordered-ast-traverse");
node_modules/grunt-ng-annotate/node_modules/ng-annotate/package.json:    "ordered-ast-traverse": "~0.1.1",

所以...我不对的是什么?任何想法,任何人?

0 个答案:

没有答案