reactjs - React-bootstrap 和深色 UI
问题描述
我是 reactjs 的新手。我正在尝试使用普通 CSS 为我的 react webapp 更改背景颜色,但是当我使用 react-bootstrap 时它不会改变。有没有办法通过 react-bootstrap 做到这一点?
我包括了 react-bootstrap
import 'bootstrap/dist/css/bootstrap.min.css';
在我使用 create-react-app 模板创建的 index.js 文件中。
解决方案
The deal with third party CSS libraries is that they always create conflicts with our CSS file. To remove this conflict either use !important
in your styling (less appreciated) or try unsettling the background colour and re-setting it,
background-color: unset;
background-color: #000;
Do mind the order of these 2 lines
推荐阅读
- python-3.x - Django 在管理列表中添加一个带有 ID url 链接的自定义链接
- angular - 如何在 formControl 中设置默认值?
- python - Python 虚拟环境激活\创建问题
- flutter - 如何在应用图标上实现通知更新
- c# - 有什么方法可以阻止 Unity 在项目根目录中放置新脚本?
- typescript - 如何以编程方式在 react-leaflet 中添加一层?
- python - 如何将空格设置为 to_csv() 的分隔符?- Python
- reactjs - NGINX问题,简单的位置和带有变量的位置没有相同的结果
- objective-c - 如何使HTTP Get请求objective-c
- python - 为了使 html 表单附加到 mysql 数据库,我得到错误̥,它说:异常类型:ValueError 异常值