【发布时间】:2017-04-27 08:50:01
【问题描述】:
我正在使用来自 valor-software 的 ng2-bootstrap。当我使用 ng serve 启动网站时,提供的页面在标题中具有以下样式标签:
<style type="text/css">/* You can add global styles to this file, and also import other style files */
</style>
<style type="text/css">/*!
* Bootstrap v3.3.7 (http://getbootstrap.com)
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*//*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}body{margin:0}
它显然是从 node_modules/bootstrap/dist/css/bootstrap.css 文件中提取第二个内联样式。我想覆盖 body 标签上的背景颜色。我可以更改 node-modules 文件夹中的 bootstrap.css 文件,但这不是正确的解决方案。
更改 style.css 文件没有任何作用。即使更改 index.html 文件似乎也无济于事。样式似乎已被覆盖。
任何帮助将不胜感激。
谢谢
【问题讨论】:
标签: css angular ng2-bootstrap