Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

successdav's avatar

Is is possible to use Inertia and blade on same project

I have an existing project that I want to integrate inertiaJs into. Considering it's an existing project, I cant just move all the pages into Vue components overnight. Is it possible to serve some pages using Inertiajs and other pages will continue to be served using blade while I progressively work on serving all the pages with inertiajs?

0 likes
9 replies
vincent15000's avatar

I don't really know inertiajs, I just try soon. What I can tell you is that inertiajs is an easy way to use all advantages of VueJS without loosing all advantages of Laravel (routing, protecting the routes with the middlewares, authentication, ...).

In the controller you have to user return Inertia:: instead of what you generally use. So my opinion is that you can progressively migrate your application to VueJS with InertiaJS and then some views will be generated by VueJS and other views by blade.

Perhaps someone can confirm ?

vincent15000's avatar

I want to add that I've already used VueJS and blade in the same project (even if it's not the best way), so it doesn't seem to be impossible.

Sinnbeck's avatar

@bryanfunk you can do this no problem. Just be sure to only add the inertia middleware to inertia routes. I do it myself and it works great

3 likes
ftina's avatar

@Sinnbeck I find that clicking to none inertia routes render them in a modal. How did you fix this – that is if you encountered the same thing?

1 like
ftina's avatar

@Sinnbeck I figured it out: use a regular <a>link</a> and not inertia's <link>inertia link</link>

1 like
vincent15000's avatar

@ftina Can you explain please ? I'm interested in knowing more precisely what you have done to get a render in a modal.

muazzamazaz's avatar

I have same issue to render blade views located in view folder with vue component of jetstream in js/layout/AppLayout.vue.

So what is the way to call my blade files

1 like

Please or to participate in this conversation.