我在Yeoman网站上跟着一个代码实验(codelab)学习,到目前为止,我已经成功地跟着走了(虽然在启动我的开发环境时遇到了一些严重的问题,但现在它不再返回任何错误了)。
所以我创建了我的项目文件夹并运行了yo
,选择了AngularJS并运行了这个东西。在整个过程中不久,我得到了一个提示? Overwrite package.json?
,我回答了y
,并得到了以下警告:
npm WARN package.json codelab@0.0.0 No license field.
npm WARN peerDependencies The peer dependency karma@>=0.9 included from karma-jasmine will no
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
npm WARN peerDependencies The peer dependency jasmine-core@* included from karma-jasmine will no
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
npm WARN peerDependencies The peer dependency karma@>=0.9 included from karma-phantomjs-launcher will no
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
npm WARN peerDependencies The peer dependency phantomjs@>=1.9 included from karma-phantomjs-launcher will no
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
npm WARN peerDependencies The peer dependency karma@~0.12.0 included from grunt-karma will no
npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency
npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
npm WARN optional dep failed, continuing fsevents@0.3.6
之后,它完成了它正在做的事情,所以我再次运行bower install
以确保(因为package.json的原因),然后运行grunt serve
。现在grunt说完成了,没有错误,但我的页面只加载main.css
。我强烈感觉缺少bootstrap.css
文件。这是它的样子,而codelab指令说应该看起来像这个。
如果您需要有关生成内容的更多信息,请参阅GitHub存储库链接。
欢迎提供任何关于我是否做错了什么的见解。
^
(像这样"angular": "^1.3.0"
)。你知道它是做什么的吗?如果我应该在引导版本之前把它放回去?除此之外,网站看起来现在应该没问题了,所以我终于准备好继续进行编码实验了。谢谢。 - Miha Šušteršič