-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Added base stylelint configuration. #154
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
Conversation
bbdba8c
to
c894ec8
Compare
@@ -30,5 +30,14 @@ module.exports = merge(baseWebpackConfig, { | |||
template: 'index.html', | |||
inject: true | |||
}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@blake-newman I think there should be a comma here, instead of on line 41.
c894ec8
to
a551f52
Compare
/ping @chrisvfritz @yyx990803 |
@blake-newman Sorry, will take another look at this soon. 😅 I took some time off to attend a wedding earlier this week and am still trying to catch up. |
"test": "{{#unit}}npm run unit{{/unit}}{{#unit}}{{#e2e}} && {{/e2e}}{{/unit}}{{#e2e}}npm run e2e{{/e2e}}"{{#eslint}}, | ||
{{#eslint}} | ||
"lint:eslint": "eslint --ext .js,.vue src test/unit/specs test/e2e/specs"{{/eslint}}{{#stylelint}}, | ||
"lint:stylelint": "stylelint 'src/**/*.@(?(s)?(a|c)ss|vue|html)' --config ./.stylelintrc.js --extract"{{/stylelint}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like stylelint can also lint scss and less, but it needs to be run again specifying that extension and syntax. See these usage examples.
Another question - what will happen with if .vue
files use a transpile-to-css language?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question we can probably have sub conditions for syntax. And as using plugin we could do less.
Scss is supported in node blob for files.
Less is currently experimental, to i have avoided it currently. Also I think Less is very little used these days. Especially if starting a new project, as scaffolding is for new projects I think we can leave Less behind until stylelint fully supports it.
Got this error when trying to use
|
Will amend noticed these issues when using today, looks like I missed up my copy paste from other project. Sorry will sort tomorrow morning. |
a551f52
to
e2e504c
Compare
e2e504c
to
926cb92
Compare
@chrisvfritz Updated all should be good now, although i would give it a quick run through as little busy and very tired, so may have made a mistake but all seems okay. |
@blake-newman Excellent! Will take a look at this soon, though maybe not this week, as I want to focus on getting those docs done if possible. 😄 |
Sure no rush! |
@blake-newman Just took another look at this and was still getting errors after generating a fresh project. 😕 I'm also concerned about users of unsupported preprocessors, such as stylus, less, or postcss. As far as I can tell, there isn't currently a way for stylelint to only parse |
Huh, it looks like the HTML parsing has been deprecated, so a different strategy entirely may be in order. Possibly by using the stylelint postcss plugin and using it as the first loader for supported languages? |
Yeah, closing this PR for now. Will recreate once stylelint becomes a bit more stable. They are doing rapid amount of changes at the moment. Feels like this should currently be user choice, as we don't want to have to depend on stylelint and have to keep on updating. |
@blake-newman I would like to complete this PR. Any plan for reopen? |
@gucong3000 You can fork and continue developing on feature/stylelint branch. |
Related: |
Runs
stylelint-webpack-plugin
during dev. Perhaps it should run on both? @yyx990803 @chrisvfritzBase config provided by stylelint. (Fixed one lint issue).