Nuxt Hooks
site-config:resolve
Type: () => void
Modify the build time site config after the module resolves it.
It's recommended to use runtime Nitro hooks if you need to modify the site config at runtime.
nuxt.config.ts
import { updateSiteConfig } from 'nuxt-site-config/kit'
export default defineNuxtConfig({
hooks: {
'site-config:resolve': () => {
if (process.env.FOO) {
updateSiteConfig({
name: 'Bar'
})
}
},
},
})Was this page helpful?
Related
Was this page helpful?