Feature flags (#543)
* Re-organize a bit controllers * Added the featureflagcontroller * Implement feature flags in the front-end * Clean env files * Clean console.log messages * Fix feature flag test
This commit is contained in:
9
client/plugins/featureFlags.js
vendored
Normal file
9
client/plugins/featureFlags.js
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
import { useFeatureFlagsStore } from '~/stores/featureFlags'
|
||||
|
||||
export default defineNuxtPlugin((nuxtApp) => {
|
||||
const featureFlagsStore = useFeatureFlagsStore()
|
||||
|
||||
nuxtApp.provide('featureFlag', (key, defaultValue = false) => {
|
||||
return featureFlagsStore.getFlag(key, defaultValue)
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user