mirror of https://github.com/zulip/zulip.git
stylelint: Move .stylelintrc to stylelint.config.js.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
parent
5d6df3dc01
commit
6c0afbb68d
|
@ -215,7 +215,7 @@ clean those files up eventually.
|
||||||
|
|
||||||
Zulip uses [stylelint](https://github.com/stylelint/stylelint) to lint
|
Zulip uses [stylelint](https://github.com/stylelint/stylelint) to lint
|
||||||
its CSS; see our
|
its CSS; see our
|
||||||
[configuration](https://github.com/zulip/zulip/blob/master/.stylelintrc)
|
[configuration](https://github.com/zulip/zulip/blob/master/stylelint.config.js)
|
||||||
for the rules we currently enforce.
|
for the rules we currently enforce.
|
||||||
|
|
||||||
#### Shell scripts
|
#### Shell scripts
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
{
|
"use strict";
|
||||||
"rules": {
|
|
||||||
# Stylistic rules for CSS.
|
module.exports = {
|
||||||
|
rules: {
|
||||||
|
// Stylistic rules for CSS.
|
||||||
"function-comma-space-after": "always",
|
"function-comma-space-after": "always",
|
||||||
"function-comma-space-before": "never",
|
"function-comma-space-before": "never",
|
||||||
"function-max-empty-lines": 0,
|
"function-max-empty-lines": 0,
|
||||||
|
@ -58,10 +60,10 @@
|
||||||
"at-rule-semicolon-space-before": "never",
|
"at-rule-semicolon-space-before": "never",
|
||||||
|
|
||||||
"comment-whitespace-inside": "always",
|
"comment-whitespace-inside": "always",
|
||||||
"indentation": 4,
|
indentation: 4,
|
||||||
|
|
||||||
# Limit language features
|
// Limit language features
|
||||||
"color-no-hex": true,
|
"color-no-hex": true,
|
||||||
"color-named": "never",
|
"color-named": "never",
|
||||||
}
|
},
|
||||||
}
|
};
|
|
@ -51,7 +51,7 @@ def run() -> None:
|
||||||
linter_config.external_linter('css', ['node', 'node_modules/.bin/stylelint'], ['css', 'scss'],
|
linter_config.external_linter('css', ['node', 'node_modules/.bin/stylelint'], ['css', 'scss'],
|
||||||
fix_arg='--fix',
|
fix_arg='--fix',
|
||||||
description="Standard CSS style and formatting linter "
|
description="Standard CSS style and formatting linter "
|
||||||
"(config: .stylelintrc)")
|
"(config: stylelint.config.js)")
|
||||||
linter_config.external_linter('eslint', ['node', 'node_modules/.bin/eslint',
|
linter_config.external_linter('eslint', ['node', 'node_modules/.bin/eslint',
|
||||||
'--quiet', '--cache', '--ext', '.js,.ts'], ['js', 'ts'],
|
'--quiet', '--cache', '--ext', '.js,.ts'], ['js', 'ts'],
|
||||||
fix_arg='--fix',
|
fix_arg='--fix',
|
||||||
|
|
Loading…
Reference in New Issue