Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scss-lint实战碰到的一些问题以及解决方案 #21

Open
youngwind opened this issue Jan 12, 2016 · 0 comments
Open

scss-lint实战碰到的一些问题以及解决方案 #21

youngwind opened this issue Jan 12, 2016 · 0 comments

Comments

@youngwind
Copy link
Owner

youngwind commented Jan 12, 2016

前言

之前在项目中引入了scss-lint,参考 #19 。在用的时候踩到一些坑,记录在这个地方。

1. 属性排序

// 比如这样的代码会报错!
.refresh {
  margin-left: 10px;
  color: $color;
}

2016-01-12 6 13 37
显然不科学啊!margin-left当然应该排在color前面啊!
后来发现scss-lint默认属性排序是按照字母排序的......参考这里 sds/scss-lint#463
解决方法:重新设置属性顺序,参考这里

linters:
  PropertySortOrder:
    order: concentric
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant