我在编译SASS时出现预期的新行错误

时间:2019-07-02 18:20:24

标签: css sass

我遇到的问题是我的SASS不仅会编译,而且还会显示相同的错误:预期的换行符

#topper, h3 {    
    text-align: center;
    text-decoration:underline;
}

.list-group{
    .active{
        text-decoration: underline;
        font-weight:bold
    }
}

显示错误。尝试了所有操作,甚至删除了左括号并放在了新行中

  ╷
1 │ #topper, h3 {
  │             ^
  ╵
  home.sass 1:13  root stylesheet

1 个答案:

答案 0 :(得分:0)

录制到Sass-lang.com和@Nit的注释中,您选择了错误的编译选项。

这是SCSS

@mixin button-base() {
  @include typography(button);
  @include ripple-surface;
  @include ripple-radius-bounded;

  display: inline-flex;
  position: relative;
  height: $button-height;
  border: none;
  vertical-align: middle;

  &:hover { cursor: pointer; }

  &:disabled {
    color: $mdc-button-disabled-ink-color;
    cursor: default;
    pointer-events: none;
  }
}

与SASS相同

@mixin button-base()
  @include typography(button)
  @include ripple-surface
  @include ripple-radius-bounded

  display: inline-flex
  position: relative
  height: $button-height
  border: none
  vertical-align: middle

  &:hover
    cursor: pointer

  &:disabled
    color: $mdc-button-disabled-ink-color
    cursor: default
    pointer-events: none