You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i'm trying to use vue-html-to-paper in nuxt
and as i use it just in a single page then i imported it locally
but i get this error every time .
"VueHtmlToPaper" is not a function
so how can i use it locally ?
The text was updated successfully, but these errors were encountered:
load it as plugin:
Create a print.js in the plugins dir, add the following code:
`import Vue from 'vue';
import VueHtmlToPaper from 'vue-html-to-paper';
const options = {
name: '_blank',
specs: [
'fullscreen=yes',
'titlebar=yes',
'scrollbars=yes'
],
styles: [
'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css',
'https://unpkg.com/kidlat-css/css/kidlat.css'
],
timeout: 1000, // default timeout before the print window appears
autoClose: true, // if false, the window will not close after printing
windowTitle: window.document.title, // override the window title
}
Vue.use(VueHtmlToPaper, options);
// or, using the defaults with no stylesheet
Vue.use(VueHtmlToPaper);`
i'm trying to use vue-html-to-paper in nuxt
and as i use it just in a single page then i imported it locally
but i get this error every time .
"VueHtmlToPaper" is not a function
so how can i use it locally ?
The text was updated successfully, but these errors were encountered: