docs: add hint about app.config placement with custom srcDir (#24252)

This commit is contained in:
Nils Wiesinger 2023-11-16 15:08:10 +01:00 committed by GitHub
parent 41ad85ed6d
commit e95026f5bb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,6 +41,8 @@ console.log(appConfig.theme)
</script> </script>
``` ```
When configuring a custom [`srcDir`](/docs/api/nuxt-config#srcdir), make sure to place the `app.config` file at the root of the new `srcDir` path.
## Typing App Config ## Typing App Config
Nuxt tries to automatically generate a TypeScript interface from provided app config so you won't have to type it yourself. Nuxt tries to automatically generate a TypeScript interface from provided app config so you won't have to type it yourself.