SASS 中的多行注释抛出错误

Tar*_*run 2 sass

我正在使用多行注释

/* * 常见样式放在这里 */ 样式定义继续...

我在编译时遇到错误。它说:

Error: Invalid CSS after "*/": expected identifier, was ""
Run Code Online (Sandbox Code Playgroud)

请注意:我没有使用 SCSS,而且我也不希望。别问我为什么。因此,请发布不包含 SCSS 解决方案的答案。

bus*_*suu 5

如果您在多行中使用注释,请尝试将注释*/与内容一起缩进至少 2 个空格。这是 codepen 上的示例: http: //codepen.io/anon/pen/XjJAbQ

/* This should work */

///*
//This won't work!
//*/

///*
//This will not work
//  */

/**
  * This is a multi line comment
  * And this should work.
  */

// This is a sass comment
.someClass
  width: 200px
  height: 200px
  background: #000
Run Code Online (Sandbox Code Playgroud)
<div class="someClass">
  
</div>
Run Code Online (Sandbox Code Playgroud)