Because each page page needs to configure their own head information,So I declare head in mixin. But as shown in the figure below, the code does not take effect. ~/plugins/xxx
const MyPlugin = {
install (Vue, options) {
Vue.mixin({
head () {
.....
return {
title: tkd['title'],
meta: [
{
hid: 'keywords', name: 'keywords', content: tkd['keywords']
},
{
hid: 'description', name: 'description', content: tkd['description']
}
]
}
}
})
}
}
Vue.use(MyPlugin)
Does head not support mixin?
<!--cmty--><!--cmty_prevent_hook--><div align="right"><sub><em>This question is available on <a href="https://nuxtjs.cmty.io">Nuxt.js</a> community (<a href="https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c1929">#c1929</a>)</em></sub></div>