0

如何忽略此错误: Class should be nested within its parent Class force-element-nesting. 当我在一行中覆盖大量嵌套的 soem 类时,我不知道如何消除此错误,例如:

// sass-lint:disable ???

.one.two.three.four .soemthing .else,
.one.three.hello .another. else 
{
    //
}

目前我正在使用// sass-lint:disable-all所有块。

4

1 回答 1

1

它应该与这个一起工作:

// sass-lint:disable force-element-nesting

.one.two.three.four .soemthing .else,
.one.three.hello .another. else 
{
    //
}

// sass-lint:enable force-element-nesting

再次启用以恢复规则。

于 2018-05-28T11:28:14.433 回答