Use postcss to combine & minify styles

This commit is contained in:
Lewis Dale 2023-01-18 08:47:00 +00:00
parent d8af8feb43
commit 3afaf86862
7 changed files with 3128 additions and 0 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
node_modules

2
assets/css/styles.css Normal file
View File

@ -0,0 +1,2 @@
@import "./global.css";
@import "./cube.css";

3086
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

28
package.json Normal file
View File

@ -0,0 +1,28 @@
{
"name": "zx-spectrum",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build:css": "postcss assets/css/styles.css > styles.css"
},
"repository": {
"type": "git",
"url": "git+https://github.com/lewisdaleuk/zx-spectrum-wp.git"
},
"author": "",
"license": "ISC",
"bugs": {
"url": "https://github.com/lewisdaleuk/zx-spectrum-wp/issues"
},
"homepage": "https://github.com/lewisdaleuk/zx-spectrum-wp#readme",
"devDependencies": {
"autoprefixer": "^10.4.13",
"cssnano": "^5.1.14",
"postcss": "^8.4.21",
"postcss-cli": "^10.1.0",
"postcss-import": "^15.1.0",
"postcss-import-ext-glob": "^2.1.1"
}
}

10
postcss.config.js Normal file
View File

@ -0,0 +1,10 @@
module.exports = {
plugins: [
require('postcss-import-ext-glob'),
require('postcss-import'),
require('autoprefixer'),
require('cssnano')({
preset: 'default',
}),
]
};

1
styles.css Normal file

File diff suppressed because one or more lines are too long