* Generate plugin list file
Removes the importing of all plugins in src/util/resolveConfig to avoid importing CSS.
Import the built plugin list file instead.
* Use `process.cwd()` instead of `__dirname` to resolve path
Co-authored-by: Federico Ciardi <fed.ciardi@gmail.com>
* Import core plugin list in resolveConfig test
* Generate plugin list prebabelify and on install
* Move generation from install to postinstall
Co-authored-by: Federico Ciardi <fed.ciardi@gmail.com>
Co-authored-by: Federico Ciardi <fed.ciardi@gmail.com>
* add nesting plugin
* rename @tailwindcss/nesting to tailwindcss/nesting
* ignore the built `nesting` plugin
* add a postcss7 compat version
* include `nesting` plugin when publishing
* add `build-plugins` script
This will allow us to keep the plugins in their dedicated folders +
tests + postcss7 compatibility files. However, when we copy over the
plugins to the root. For example `plugins/nesting/` -> `nesting/` we
skip files like `.test.js` and `.postcss7.js`.
* build plugins when running `prepublishOnly`
* improve compat mode
We will use a glob so that we can move all *.postcss7.* files to just
*.* likewise we will also backup to *.* to *.postcss8.* for restoring
purposes.
Concrete example:
- Current state:
- index.js // PostCSS 8 implementation
- index.postcss7.js // PostCSS 7 implementation
- Run "compat"
- index.js // PostCSS 7 implementation
- index.postcss7.js // PostCSS 7 implementation
- index.postcss8.js // PostCSS 8 implementation (Backup of original)
- Run "compat:restore"
- index.js // PostCSS 8 implementation
- index.postcss7.js // PostCSS 7 implementation
- X index.postcss8.js // PostCSS 8 implementation (Removed)
* Update README.md
* ensure we `npm install` before publishing
Co-authored-by: Adam Wathan <adam.wathan@gmail.com>
* ensure postcss 7 is dropped from dev dependencies as well
Drop incorrect "help" text
* ensure we are cloning nodes
This is an issue in postcss 7 and fixed in postcss 8. However the compat build still suffers form this issue.
* add integration test tools
* setup jest in the integrations folder
* add `test:integrations` script
The default `npm test` script will ignore all the tests in the
`integrations` folder.
* add integration tests with `webpack 5`
* add integration tests with `postcss-cli`
* add `npm run install:integrations` script
This script will run `npm install` in every integration, and in the
integrations folder itself (to setup Jest for example).
* add `toIncludeCss` custom matcher
* increate Jest timeout for integration tests
* add integration tests with `vite`
* add integration tests with `webpack 4`
* add isomorphic fetch
* add the ability to wait for specific stdout/stderr output
* write vite tests, assert using API calls
We will wait for the correct stdout/stderr output, once we know that we
can request the fresh css, we will fetch it and make assertions
accordingly.
Port is currently hardcoded, maybe we should use a packaage to ensure
that we use a free port.
* add integration tests with `rollup`
* add integration tests with `parcel`
* run all integration tests in band
* add .gitignore in integrations folder
* WIP
* WIP
* Finish combining JIT and AOT plugins
Still lots of clean up that can be done in some of the more complex ones, but at least it's one file per plugin now.
* Remove unused import
* Fix AOT generation bugs
* Move corePlugins/index.js to corePlugins.js
* Convert JIT files to ESM
* Move tests
* Reorder core plugins to match JIT order
* Update AOT apply tests
* Unify utils
* Combine plugin lists to one single source of truth
* Finish resolving merge conflicts, fix tests
Co-authored-by: Adam Wathan <adam.wathan@gmail.com>