mirror of
https://github.com/LibreOffice/online.git
synced 2025-08-16 17:42:05 +00:00
loleaflet: introduce "stylelint" a modern linter for CSS
Change-Id: I8a7427eeb3b838baac8a6669d5313dc0d53d9ddd Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102199 Tested-by: Pedro Silva <pedro.silva@collabora.com> Reviewed-by: Pedro Silva <pedro.silva@collabora.com>
This commit is contained in:

committed by
Pedro Silva

parent
175ac6e740
commit
d7353acf96
1
loleaflet/.gitignore
vendored
1
loleaflet/.gitignore
vendored
@ -1,6 +1,5 @@
|
||||
node_modules
|
||||
node_cache
|
||||
.*
|
||||
tmp/**/*
|
||||
*.iml
|
||||
*.sublime-*
|
||||
|
13
loleaflet/.stylelintrc.json
Normal file
13
loleaflet/.stylelintrc.json
Normal file
@ -0,0 +1,13 @@
|
||||
{
|
||||
"rules": {
|
||||
"indentation": "tab",
|
||||
"string-quotes": "single",
|
||||
"no-duplicate-selectors": true,
|
||||
"selector-combinator-space-after": "always",
|
||||
"selector-attribute-quotes": "always",
|
||||
"selector-attribute-brackets-space-inside": "never",
|
||||
"function-url-quotes": ["always", {
|
||||
"except": ["empty"]
|
||||
}]
|
||||
}
|
||||
}
|
@ -447,6 +447,8 @@ $(INTERMEDIATE_DIR)/loleaflet-src.js: $(call prereq_loleaflet)
|
||||
|
||||
$(DIST_FOLDER)/bundle.css: $(call prereq_css)
|
||||
@mkdir -p $(dir $@)
|
||||
@echo "Checking for CSS errors..."
|
||||
@$(NODE) node_modules/stylelint/bin/stylelint.js --config $(srcdir)/.stylelintrc.json $(srcdir)/css/*.css
|
||||
$(call bundle_css)
|
||||
|
||||
$(DIST_FOLDER)/bundle.js: $(INTERMEDIATE_DIR)/loleaflet-src.js $(call prereq_all)
|
||||
|
@ -23,7 +23,9 @@
|
||||
"uglifycss": "0.0.29",
|
||||
"uglifyify": "5.0.2",
|
||||
"vex-js": "4.1.0",
|
||||
"typescript": "3.9.5"
|
||||
"typescript": "3.9.5",
|
||||
"stylelint-config-standard": "20.0.0",
|
||||
"stylelint": "13.7.0"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
Reference in New Issue
Block a user