加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > 安全 > 正文

angularjs – 不能在简单的Yeoman角上使用咕噜声

发布时间:2020-12-17 07:35:29 所属栏目:安全 来源:网络整理
导读:尝试通过Yeoman启动一个简单的角度应用程序,使用本指南中的步骤 http://www.sitepoint.com/kickstart-your-angularjs-development-with-yeoman-grunt-and-bower/ 并尝试运行grunt或grunt服务器时出现此错误: Loading "Gruntfile.js" tasks...ERRORError: Ca
尝试通过Yeoman启动一个简单的角度应用程序,使用本指南中的步骤
http://www.sitepoint.com/kickstart-your-angularjs-development-with-yeoman-grunt-and-bower/

并尝试运行grunt或grunt服务器时出现此错误:

Loading "Gruntfile.js" tasks...ERROR
Error: Cannot find module 'load-grunt-tasks'
Warning: Task "default" not found. Use --force to continue.

这是我的版本:

yo --version && grunt --version && bower --version
1.1.2<
grunt-cli v0.1.13
grunt v0.4.4
1.3.1

请参阅此操作的截屏视频:
http://screencast.com/t/4ToPw3SlL2

我今天刚遇到同样的问题,设法用这里的答案来解决它.

基本上我需要将npm更新到最新版本,
使用此命令(Node-v0.10.29包附带的npm已过时)

npm update npm -g

要么

sudo npm update npm -g (i used this command on my mac)

然后键入此命令

npm --version (it should show 1.5.0-alpha-4 or later version)

然后键入grunt serve命令

grunt serve

如果仍有问题,请尝试运行这些命令

npm install

要么

sudo npm install (i used this command on my mac)

然后再次尝试grunt serve命令,

grunt serve

这一次,它对我有用.

如果没有,请尝试此命令

bower install (i did not have to use this command)

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读