diff --git a/CHANGELOG.md b/CHANGELOG.md index 2acbd8f..25b2ff1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] -- Nothing yet! +### Added + +- Remove `dist` folder and related dependencies ([#29](https://github.com/tailwindlabs/tailwindcss-aspect-ratio/pull/29)) ## [0.4.0] - 2021-12-09 diff --git a/dist/.gitignore b/dist/.gitignore deleted file mode 100644 index 2f41fac..0000000 --- a/dist/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -* -!.gitignore -!.npmignore diff --git a/dist/.npmignore b/dist/.npmignore deleted file mode 100644 index e69de29..0000000 diff --git a/package.json b/package.json index e655174..711a4ae 100644 --- a/package.json +++ b/package.json @@ -14,15 +14,12 @@ "trailingComma": "es5" }, "scripts": { - "test": "jest", - "prepublishOnly": "node scripts/build.js" + "test": "jest" }, "peerDependencies": { "tailwindcss": ">=2.0.0 || >=3.0.0 || >=3.0.0-alpha.1" }, "devDependencies": { - "autoprefixer": "10", - "clean-css": "^4.2.1", "jest": "^27.2.4", "postcss": "^8.2.4", "tailwindcss": "^3.0.0", diff --git a/scripts/build.js b/scripts/build.js deleted file mode 100644 index 8ee5212..0000000 --- a/scripts/build.js +++ /dev/null @@ -1,36 +0,0 @@ -const fs = require('fs') -const postcss = require('postcss') -const tailwind = require('tailwindcss') -const CleanCSS = require('clean-css') - -function buildDistFile(filename) { - return postcss([ - tailwind({ - corePlugins: false, - plugins: [require('../src/index.js')], - }), - require('autoprefixer'), - ]) - .process('@tailwind components', { - from: null, - to: `./dist/${filename}.css`, - map: false, - }) - .then((result) => { - fs.writeFileSync(`./dist/${filename}.css`, result.css) - return result - }) - .then((result) => { - const minified = new CleanCSS().minify(result.css) - fs.writeFileSync(`./dist/${filename}.min.css`, minified.styles) - }) - .catch((error) => { - console.log(error) - }) -} - -console.info('Building CSS...') - -Promise.all([buildDistFile('aspect-ratio')]).then(() => { - console.log('Finished building CSS.') -})