I'm using Vuex and the Vue-i18n plugin in my app. I'm getting undefined on my non-reactive array that I want to share between the plugins. If I log the array in both files, the i18n file prints first (undefined) and vuex prints the array as expected after. This leads me to believe I'm referencing the array in the i18n plugin before the array is created in the store file. I've perused the import/export MDN pages and I believe my imports here are synchronous? That's the only other cause I can think of. Here's the i18n plugin in question
My files are as follows
main.js
import store from '@/store'
import i18n from '@/i18n'
const app = new Vue({
el: '#app',
store,
i18n,
template: '<App/>',
components: { App }
})
vuex
export const tabs = [
'tab1',
'tab2',
'tab3',
'tab4',
'tab5'
]
console.log(tabs)
i18n
import { tabs } from '@/i18n'
console.log(tabs)