【发布时间】:2020-09-18 13:35:36
【问题描述】:
所以之前有人问过类似的问题,但没有得到答案。
我正在学习 SASS,并在 vs 代码中使用实时 sass 编译器,但它没有更新任何内容。我可以让 app.css 文件显示更改的唯一方法是按下观看按钮并基本上重置事物。它以前不这样做。我保存文件后立即显示所有更改。输出终端中似乎没有任何显示问题的内容。这是在本地环境中工作时查看 sass 文件实时更改的唯一方法还是有更好的方法。
.header {
height: 8vh;
background-color: #131921;
position: sticky;
top: 0;
z-index: 100;
align-items: center;
display: flex;
color: #fff;
padding: 30px 20px;
&__logo {
width: 100px;
object-fit: contain;
margin: 0 20px;
}
&__search {
display: flex;
flex: 1;
align-items: center;
border-radius: 35px;
}
&__searchIcon {
padding: 5px;
height: 36px !important;
width: 36px !important;
background-color: #cd9042;
border-radius: 0 6px 6px 0 !important;
}
&__searchInput {
padding: 10px;
border: none;
width: 100%;
border-radius: 6px 0 0 6px !important;
}
&__nav {
display: flex;
justify-content: space-evenly;
}
&__boxes {
display: flex;
flex-direction: column;
align-items: flex-start;
color: #fff;
margin: 0 10px;
text-transform: capitalize;
text-align: left;
}
&__boxesFirstLine {
font-size: 12px;
line-height: 14px;
font-weight: 400;
color: rgba(255, 255, 255, 0.7);
}
&__boxesSecondLine {
font-size: 14px;
font-weight: 700;
line-height: 15px;
padding-bottom: 5px;
padding-right: 9px;
}
&__basketText {
color: #fff;
font-size: 14px;
line-height: 15px;
font-weight: 700;
padding-bottom: 5px;
padding-right: 9px;
text-transform: capitalize;
}
}
【问题讨论】:
-
这里是scss文件的内容。我不认为这是一个问题,因为它会在编译器重新启动后立即工作。
-
你的 sass 编译器和 vscode 的版本?
-
vs 代码版本 1.49 sass 编译器 3.0.0
-
你能给我们看一张你的IDE的截图,它显示编译状态的部分吗?
-
你的意思是输出终端吗?如果是这样
标签: css visual-studio-code sass