Closed shiowwj closed 2 years ago
you should use ssr false
plugins: [{ src: '~/plugins/typewriter.js' , ssr: false } ]
,
The reason may be SSR so you can try to use it the way @desdo09 recommends or change the plugin name to typewriter.client.js
- both will result the same. More about client or server side only plugins can be found here: https://nuxtjs.org/docs/directory-structure/plugins#name-conventional-plugin.
Closing this issue due to long unactivity.
How did you handle corejs incompatibility issues?
replace Vue.use(Typewriter, { name: 'vue-typewriter' })
with
Vue.component('Typewriter', Typewriter)
Unable to use the component on Vue.
Created Plugins file ~/plugins/typewriter.js `import Vue from 'vue' import Typewriter from "typewriter-vue";
Vue.use(Typewriter, { name: 'vue-typewriter' })
console.log('plugin typewriter is locked and loaded') `
added this to nuxt.config.js
plugins: [ '~/plugins/typewriter.js' ],
Using the component on a page view:
`