我正在关注 yeoman 教程 http://yeoman.io/codelab/prepare-production.html一切工作正常,直到我尝试使用“grunt”命令启动我的项目,然后出现以下错误:
Running "autoprefixer:dist" (autoprefixer) taskAutoprefixer's process() method is deprecated and will removed in next major release. Use postcss([autoprefixer]).process() insteadFile .tmp/styles/main.css created.
jit-grunt: Plugin for the "ngtemplates" task not found.If you have installed the plugin already, please setting the static mapping.See https://github.com/shootaroo/jit-grunt#static-mappings
Warning: Task "ngtemplates" failed. Use --force to continue.
Aborted due to warnings.
我使用 Linux Mint 17
最佳答案
A workaround发布在生成器角度 github 上。尝试修改 Gruntfile.js 以使 jit-grunt block 如下所示:
// Automatically load required Grunt tasks
require('jit-grunt')(grunt, {
useminPrepare: 'grunt-usemin',
ngtemplates: 'grunt-angular-templates',
cdnify: 'grunt-google-cdn'
});
关于gruntjs - Yeoman 使用 "grunt"命令启动项目时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31166376/