When i try to npm start
, error:
No configuration provided for .../main.scss, Error in plugin "gulp-stylelint".
Someone help me!
No configuration provided for .../main.scss, Error in plugin "gulp-stylelint". Someone help me! Show activity on this post. You should extend the standard config if you want stylelint to enforce stylistic conventions like spaces after colons in declarations and use the recommended config if you don't.
The other thing you need to do is update your CLI configuration to create SCSS files instead of CSS files when you create new components. There are two ways to do this — using the CLI command or adding the reference manually. To use the command type the following into your terminal: ng config schematics.@schematics/angular:component.styleext scss
It automatically compiles your . scss files into .css files for the browser to read. Why use SCSS? SCSS allows for use of variables, nesting selectors, imports, mixins, and other features that are not yet available in CSS.
SCSS is a preprocessor for CSS that lets you use additional features in your CSS stylesheets. It automatically compiles your . scss files into .css files for the browser to read. Why use SCSS?
The quickest way to add a configuration to stylelint is to extend one of the official shared configs:
You should extend the standard config if you want stylelint to enforce stylistic conventions like spaces after colons in declarations and use the recommended config if you don't.
To use the standard config you should first install it as a devDependency:
npm install stylelint-config-standard --save-dev
Then create a configuration file, e.g. .stylelintrc.json
, in the root of your project and add the following content to it:
{
"extends": "stylelint-config-standard"
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With