Browse Source

configure postcss/autoprefixer

develop
James Fenn 7 months ago
parent
commit
6e9bc9a475
3 changed files with 17 additions and 2 deletions
  1. +4
    -2
      Makefile
  2. +3
    -0
      package.json
  3. +10
    -0
      postcss.config.js

+ 4
- 2
Makefile View File

@@ -17,8 +17,10 @@ package-install.lock: package.json
${NPM} install
touch package-install.lock

assets/css/styles.css: install assets/css/styles.scss
${NPX} sass assets/css/styles.scss assets/css/styles.css
assets/css/styles.css: assets/css/styles.scss
${NPX} sass $^ $@.tmp
${NPX} -p postcss-cli postcss $@.tmp -o $@
rm $@.tmp $@.tmp.map

build: install assets/css/styles.css
${NPX} @11ty/eleventy


+ 3
- 0
package.json View File

@@ -22,10 +22,13 @@
"@11ty/eleventy-plugin-rss": "^1.0.7",
"@11ty/eleventy-plugin-syntaxhighlight": "^2.0.3",
"@doubledotlabs/dot.css": "0.1.2",
"autoprefixer": "^9.8.5",
"bootstrap": "^4.5.0",
"cssnano": "^4.1.10",
"fs": "0.0.1-security",
"markdown-it": "^10.0.0",
"markdown-it-anchor": "^5.2.5",
"postcss-cli": "^7.1.1",
"sass": "^1.23.2"
}
}

+ 10
- 0
postcss.config.js View File

@@ -0,0 +1,10 @@
module.exports = (ctx) => ({
map: { annotation: false },
parser: ctx.options.parser,
plugins: {
autoprefixer: {},
cssnano: {
preset: 'default'
},
},
});

Loading…
Cancel
Save