我尝试将 bootstrap 与 Bower 一起使用,但由于它克隆了整个存储库,因此没有 CSS 和其他内容。
这是否意味着我需要在我自己的构建过程中包含构建 Bootstrap?或者如果我错了,正确的工作流程是什么?
最佳答案
我最终使用以下内容结束:
bower install --save http://twitter.github.com/bootstrap/assets/bootstrap.zip
对我来说似乎更干净,因为它不会克隆整个存储库,它只解压缩所需的 Assets 。
这样做的缺点是它破坏了 Bower 的理念,因为 bower 更新
不会更新 bootstrap。
但我认为它仍然比使用 bower install bootstrap
然后在工作流程中构建 bootstrap 更干净。
我想这是一个选择问题。
更新:似乎他们现在版本了一个 dist 文件夹(请参阅: https://github.com/twbs/bootstrap/pull/6342 ),所以只需使用 bower install bootstrap
并指向 中的 Assets dist
文件夹
关于twitter-bootstrap - 将 Bootstrap 与 Bower 一起使用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14450408/