mirror of
https://github.com/Lissy93/dashy.git
synced 2024-12-01 04:33:02 +03:00
🔥 Removes provides from App.vue, replaced with Store
This commit is contained in:
parent
b55f96c839
commit
5e6f78e6e7
16
src/App.vue
16
src/App.vue
@ -11,8 +11,6 @@
|
||||
import Header from '@/components/PageStrcture/Header.vue';
|
||||
import Footer from '@/components/PageStrcture/Footer.vue';
|
||||
import LoadingScreen from '@/components/PageStrcture/LoadingScreen.vue';
|
||||
// import { componentVisibility } from '@/utils/ConfigHelpers';
|
||||
import ConfigAccumulator from '@/utils/ConfigAccumalator';
|
||||
import { welcomeMsg } from '@/utils/CoolConsole';
|
||||
import ErrorHandler from '@/utils/ErrorHandler';
|
||||
import {
|
||||
@ -22,11 +20,6 @@ import {
|
||||
language as defaultLanguage,
|
||||
} from '@/utils/defaults';
|
||||
|
||||
const Accumulator = new ConfigAccumulator();
|
||||
const config2 = Accumulator.config();
|
||||
// const visibleComponents = componentVisibility(config.appConfig) || defaultVisibleComponents;
|
||||
const visibleComponents = defaultVisibleComponents;
|
||||
|
||||
export default {
|
||||
name: 'app',
|
||||
components: {
|
||||
@ -34,15 +27,9 @@ export default {
|
||||
Footer,
|
||||
LoadingScreen,
|
||||
},
|
||||
provide: {
|
||||
config: config2,
|
||||
visibleComponents,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
isLoading: true, // Set to false after mount complete
|
||||
showFooter: visibleComponents.footer,
|
||||
visibleComponents,
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
@ -66,6 +53,9 @@ export default {
|
||||
sections() {
|
||||
return this.$store.getters.pageInfo;
|
||||
},
|
||||
visibleComponents() {
|
||||
return this.$store.getters.visibleComponents;
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('initializeConfig');
|
||||
|
Loading…
Reference in New Issue
Block a user