diff options
author | 2021-11-20 11:17:58 +0200 | |
---|---|---|
committer | 2021-11-20 10:17:58 +0100 | |
commit | 8ca77e7237ffe2e97f6f64bed21b128ffad5c50f (patch) | |
tree | 25750397c15406e136e5b7e80766b484ca3e11bd /docs/src | |
parent | 37a20c9ad488e12ade2b13f14aee72cc30e38415 (diff) | |
download | astro-8ca77e7237ffe2e97f6f64bed21b128ffad5c50f.tar.gz astro-8ca77e7237ffe2e97f6f64bed21b128ffad5c50f.tar.zst astro-8ca77e7237ffe2e97f6f64bed21b128ffad5c50f.zip |
Add migration guide for Tailwind CSS (#1940)
Added some proposed changes to help others migrate their Astro projects built with Tailwind CSS, over to the new version. This is what I had to do to get it to work :)
Diffstat (limited to 'docs/src')
-rw-r--r-- | docs/src/pages/migration/0.21.0.md | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/docs/src/pages/migration/0.21.0.md b/docs/src/pages/migration/0.21.0.md index 04dd7f7b6..9bf83e3a1 100644 --- a/docs/src/pages/migration/0.21.0.md +++ b/docs/src/pages/migration/0.21.0.md @@ -208,6 +208,20 @@ Autoprefixer is no longer run by default. To enable: }, }; ``` +### Tailwind CSS + +Ensure you have PostCSS installed. This was optional in previous releases, but is required now: + +1. Intall the latest version of postcss (`npm i -D postcss`) +2. Create a `postcss.config.cjs` file at the root of your project with: + ```js + module.exports = { + plugins: { + tailwindcss: {}, + }, + }; + ``` +For more information, read the [Tailwind CSS documentation](https://tailwindcss.com/docs/installation#add-tailwind-as-a-post-css-plugin) [snowpack]: https://www.snowpack.dev [vite]: https://vitejs.dev |