question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Any plan for StyleLint?

See original GitHub issue

I have a new parser for PostCSS/StyleLint, postcss-html. features about vue:

  • Compatible with vue component
  • Support automatically fixes of StyleLint.
  • Support syntax definded in <style lang="*">
  • Syntax detection by file extensions for non vue component file.

Usage:

stylelint "**/*.{vue,html,css,sss,less,scss,sass}" --custom-syntax postcss-html

Related:

  • #154
  • vuejs/vue-loader#303
  • stylelint/stylelint#2975

/CC @dan-gamble

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:7
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

4reactions
gucong3000commented, Sep 12, 2017

A temporary solution is separate your html, (s)css and js files to let PostCSS’s plugin stylelint to process.

I used another solution, postcss-html for stylelint CLI

stylelint "**/*.{vue,htm,html,css,sss,less,scss,sass}" --custom-syntax postcss-html
2reactions
aicommented, Aug 4, 2017

Stylelint is used by Facebook, Wikipedia and GitHub.

create-react-app will support it in 2.0.

Right now it is the most popular CSS linter.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Rules | Stylelint
Rules. There are over 170 rules that help you: avoid errors; enforce non-stylistic conventions; enforce stylistic conventions (frozen). The rules:.
Read more >
Changelog | Stylelint
Fixed: shorthand-property-no-redundant-values message to be consistent ... Fixed: feature-name-no-unknown false positives for prefers-color-scheme (#3951).
Read more >
indentation - Stylelint
The setting baseIndentLevel allows you to define a relative indent level based on CSS code block opening or closing line.
Read more >
no-descending-specificity - Stylelint
Disallow selectors of lower specificity from coming after overriding selectors of higher specificity. ... Source order is important in CSS, and when two...
Read more >
selector-class-pattern - Stylelint
A string will be translated into a RegExp like so new RegExp(yourString) — so be sure to escape properly. The selector value after...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found