Nuxt/docs/3.api/3.utils/update-app-config.md

18 lines
404 B
Markdown
Raw Normal View History

# `updateAppConfig`
Updates [app config](/docs/guide/directory-structure/app-config) using deep assignment. Existing (nested) properties will be preserved.
**Usage:**
```js
2023-06-05 15:03:06 +00:00
const appConfig = useAppConfig() // { foo: 'bar' }
const newAppConfig = { foo: 'baz' }
updateAppConfig(newAppConfig)
console.log(appConfig) // { foo: 'baz' }
```
::ReadMore{link="/docs/guide/directory-structure/app-config"}