Skip to content

Commit

Permalink
chore: add nuxt 3 usage
Browse files Browse the repository at this point in the history
  • Loading branch information
sonofmagic committed Aug 9, 2023
1 parent eef18fa commit b735483
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
4 changes: 4 additions & 0 deletions apps/nuxt-app/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ export default defineNuxtConfig({
autoprefixer: {}
}
},
// https://github.com/nuxt/nuxt/issues/20428
experimental: {
inlineSSRStyles: false
},
modules: [
[
nuxtPlugin,
Expand Down
24 changes: 24 additions & 0 deletions packages/unplugin-tailwindcss-mangle/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ It is recommended to read the documentation of [tailwindcss-patch](https://githu
- [5. Register this plugin](#5-register-this-plugin)
- [vite](#vite)
- [webpack](#webpack)
- [Nuxt 3](#nuxt-3)
- [Options](#options)
- [Notice](#notice)
- [Migration form v1 to v2](#migration-form-v1-to-v2)
Expand Down Expand Up @@ -111,6 +112,29 @@ module.exports = defineConfig({

```

#### Nuxt 3

```ts
import nuxtPlugin from 'unplugin-tailwindcss-mangle/nuxt'
export default defineNuxtConfig({
//...
// https://github.com/nuxt/nuxt/issues/20428
// you must set this option to false to enable vite extract css
experimental: {
inlineSSRStyles: false
},
modules: [
[
nuxtPlugin,
{
// options
}
]
]
})

```

## Options

[types.ts]('./src/types.ts')
Expand Down

0 comments on commit b735483

Please sign in to comment.