Skip to content

Commit

Permalink
docs: external configuration table (#9189)
Browse files Browse the repository at this point in the history
Co-authored-by: Pooya Parsa <pooya@pi0.io>
  • Loading branch information
nathanchase and pi0 committed Nov 21, 2022
1 parent b2933cd commit 34ae992
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
24 changes: 24 additions & 0 deletions docs/content/1.docs/1.getting-started/3.configuration.md
Expand Up @@ -111,3 +111,27 @@ Types support | ✅ Partial | ✅ Yes
Configuration per Request | ❌ No | ✅ Yes
Hot Module Replacement | ❌ No | ✅ Yes
Non primitive JS types | ❌ No | ✅ Yes

:ReadMore{link="/docs/guide/directory-structure/external-configuration"}

## External Configuration Files

Nuxt uses `nuxt.config.ts` file as the single source of trust for configurations and skips reading external configuration files. During the course of building your project, you may have a need to configure those. The following table highlights common configurations and, where applicable, how they can be configured with Nuxt.

Name | Config File | How To Configure
|---------------------------------------------|---------------------------|-------------------------
| [Nitro](https://nitro.unjs.io/) | ~~`nitro.config.ts`~~ | Use [`nitro`](/docs/api/configuration/nuxt-config#nitro) key in `nuxt.config`
| [PostCSS](https://postcss.org) | ~~`postcss.config.js`~~ | Use [`postcss`](/docs/api/configuration/nuxt-config#postcss) key in `nuxt.config`
| [Vite](https://vitejs.dev) | ~~`vite.config.ts`~~ | Use [vite](/docs/api/configuration/nuxt-config#vite) key in `nuxt.config`
| [webpack](https://webpack.js.org/) | ~~`webpack.config.ts`~~ | Use [`webpack`](/docs/api/configuration/nuxt-config#webpack-1) key in `nuxt.config`

Here is a list of other common config files:

Name | Config File | How To Configure
|---------------------------------------------|-------------------------|--------------------------
| [Typescipt](https://www.typescriptlang.org) | `tsconfig.json` | [More Info](/docs/guide/concepts/typescript#nuxttsconfigjson)
| [ESLint](https://eslint.org) | `.eslintrc.js` | [More Info](https://eslint.org/docs/latest/user-guide/configuring/configuration-files)
| [Prettier](https://stylelint.io) | `.prettierrc.json` | [More Info](https://prettier.io/docs/en/configuration.html)
| [Stylelint](https://stylelint.io) | `.stylelintrc.json` | [More Info](https://stylelint.io/user-guide/configure)
| [TailwindCSS](https://tailwindcss.com) | `tailwind.config.js` | [More Info](https://tailwindcss.nuxt.dev/tailwind/config/)
| [Vitest](https://vitest.dev) | `vitest.config.ts` | [More Info](https://vitest.dev/config/)
2 changes: 2 additions & 0 deletions playground/nuxt.config.ts
@@ -1,3 +1,5 @@
export default defineNuxtConfig({
webpack: {

}
})

0 comments on commit 34ae992

Please sign in to comment.