Answer the question
In order to leave comments, you need to log in
How to specify in Inertiajs to ignore a custom tag?
I understand with inertiajs. When using icons, I get a bunch of warnings in the console.
[Vue warn]: Failed to resolve component: ion-icon
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
createInertiaApp({
resolve: async name => {
let page = (await import(`./Pages/${name}`)).default;
if (page.layout === undefined) {
page.layout = Layout;
}
return page;
},
setup({el, App, props, plugin}) {
const VueApp = createApp({render: () => h(App, props)});
VueApp.config.compilerOptions.isCustomElement = tag => tag.startsWith('ion-')
return VueApp.use(plugin)
.use(VueTextareaAutosize)
.use(ElementPlus)
.use(VueClipboard)
.use(moment)
.component('Link', Link)
.component('Head', Head)
.mount(el);
},
title: title => `My app - ${title}`,
})
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question