mirror of
https://github.com/go-gitea/gitea.git
synced 2024-11-15 09:58:28 -07:00
Switch CSS minifier to cssnano (#9260)
This results in around 4kB saving in CSS size and also resolves with a particular issue on git bash which had issues with the format of the lessc arguments.
This commit is contained in:
parent
d7c52b8dce
commit
9ff5b75559
6
Makefile
6
Makefile
@ -469,9 +469,9 @@ css: node-check $(CSS_DEST)
|
||||
|
||||
$(CSS_DEST): node_modules $(CSS_SOURCES)
|
||||
npx stylelint web_src/less
|
||||
npx lessc --clean-css="--s0 -b" web_src/less/index.less public/css/index.css
|
||||
$(foreach file, $(filter-out web_src/less/themes/_base.less, $(wildcard web_src/less/themes/*)),npx lessc --clean-css="--s0 -b" web_src/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;)
|
||||
npx postcss --use autoprefixer --no-map --replace public/css/*
|
||||
npx lessc web_src/less/index.less public/css/index.css
|
||||
$(foreach file, $(filter-out web_src/less/themes/_base.less, $(wildcard web_src/less/themes/*)),npx lessc web_src/less/themes/$(notdir $(file)) > public/css/theme-$(notdir $(call strip-suffix,$(file))).css;)
|
||||
npx postcss --use autoprefixer --use cssnano --no-map --replace public/css/*
|
||||
|
||||
.PHONY: javascripts
|
||||
javascripts:
|
||||
|
@ -13,11 +13,11 @@
|
||||
"babel-loader": "8.0.6",
|
||||
"core-js": "3.4.1",
|
||||
"css-loader": "3.2.0",
|
||||
"cssnano": "4.1.10",
|
||||
"eslint": "6.6.0",
|
||||
"eslint-config-airbnb-base": "14.0.0",
|
||||
"eslint-plugin-import": "2.18.2",
|
||||
"less": "3.10.3",
|
||||
"less-plugin-clean-css": "1.5.1",
|
||||
"postcss-cli": "6.1.3",
|
||||
"style-loader": "1.0.0",
|
||||
"stylelint": "11.1.1",
|
||||
|
Loading…
Reference in New Issue
Block a user