错误:找不到模块'connect-livereload'。

18

我按照网站http://yeoman.io/提供的步骤进行操作,完成后出现以下错误信息:

`$ grunt Loading "Gruntfile.js" tasks...ERROR

Error: Cannot find module 'connect-livereload' Warning: Task "default" not found. Use --force to continue`

在我的 package.json 文件中,我有所有的依赖包:

"connect-livereload": "~0.2.0", "grunt-google-cdn": "~0.2.0", "grunt-ngmin": "~0.0.2", "grunt-contrib-livereload": "~0.1.2"

2个回答

44

我有同样的问题。我的解决方法是:

npm install --save-dev connect-livereload
npm install

可能 "npm install" 就足够了。


不错。也帮助了我的构建。+1 - ehime

0

安装

npm install connect-livereload --save-dev

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接