[英]After writing css in Scss file, how to put default css in top position into Compiled css file
Here My Scss code这是我的Scss代码
*{
padding: 0;
margin: 0;
box-sizing: border-box;
}
body {
font-family: 'Montserrat','Poppins', sans-serif;
font-size: 1rem;
}
.header_area {
.main_nav {
.site_logo {
font-size: 2rem;
}
}
}
And Here my Complied css code.这是我编译的 css 代码。 My global css Like
*{...}
and body{...}
Now I want to see my global code in top position into Compiled css file.我的全局 css Like
*{...}
和body{...}
现在我想在顶部 position 中查看我的全局代码到已编译的 css 文件中。
.header_area .main_nav .site_logo {
font-size: 2rem;
}
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}
body {
font-family: "Montserrat", "Poppins", sans-serif;
}/*# sourceMappingURL=app.css.map */
SCSS is written get first priority. SCSS 是写得到优先级的。 you can easily set your global css top frist split the css and made order format like
您可以轻松设置您的全局 css 顶部第一个拆分 css 并制作订单格式,如
@import './header'; @import './header';
@import './main'; @import './main';
@import './footer'; @import './footer';
change your file names:_header.scss, _main.scss and _footer.scss and compile that into a css file containing all the scss files in one更改文件名:_header.scss、_main.scss 和 _footer.scss 并将其编译为 css 文件,其中包含所有 scss 文件
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.