Closed
Description
Would be great if, within the
sentry.client.config.ts
file, we would able to use the runtime config:https://nuxt.com/docs/api/composables/use-runtime-config
Example from other module:
https://formkit.com/getting-started/installation#using-environment-variables-in-formkitconfigtsThe code below
import * as Sentry from '@sentry/nuxt' Sentry.init({ enabled: process.env.NUXT_PUBLIC_SENTRY_ENABLED, })Would then become:
import * as Sentry from '@sentry/nuxt' export default defineSentryConfig(() => { const config = useRuntimeConfig() Sentry.init({ enabled: config.public.sentry.enabled, }) })
Metadata
Metadata
Assignees
Type
Projects
Status
Waiting for: Product Owner