Open hakimov-dev opened 1 year ago
Depends on you setup, but with vue 2 you likely have a main.js
looking like this :
import Vue from 'vue'
import VueMeta from 'vue-meta'
import { createRouter } from './router'
import { createStore } from './store'
import App from './App.vue'
Vue.use(VueMeta)
export function createApp() {
const router = createRouter()
const store = createStore()
const app = new Vue({
name: 'root',
render: (el) => el(App),
router,
store,
})
return {
app,
router,
store,
}
}
You can then access app
like this :
const { app, router, store } = createApp()
const meta = app.$meta()
Someone can explain which app file or folder ?