primevue-mirror/apps/showcase/plugins/app-state.js

22 lines
536 B
JavaScript

import { reactive } from 'vue';
const $appState = {
install: (Vue, options) => {
Vue.config.globalProperties.$appState = reactive({
preset: 'Aura',
primary: 'noir',
surface: null,
darkTheme: false,
codeSandbox: false,
sourceType: 'options-api',
newsActive: false,
announcement: null,
storageKey: 'primevue'
});
}
};
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use($appState);
});