Nuxt/docs/3.api/5.kit/10.runtime-config.md

851 B

title description links
Runtime Config Nuxt Kit provides a set of utilities to help you access and modify Nuxt runtime configuration.
label icon to size
Source i-simple-icons-github https://github.com/nuxt/nuxt/blob/main/packages/kit/src/runtime-config.ts xs

useRuntimeConfig

At build-time, it is possible to access the resolved Nuxt runtime config.

Type

function useRuntimeConfig (): Record<string, unknown>

updateRuntimeConfig

It is also possible to update runtime configuration. This will be merged with the existing runtime configuration, and if Nitro has already been initialized it will trigger an HMR event to reload the Nitro runtime config.

function updateRuntimeConfig (config: Record<string, unknown>): void | Promise<void>