question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Persistent layouts doesn't work in Vue 3

See original GitHub issue

Versions:

  • @inertiajs/inertia version: 0.8.5
  • @inertiajs/inertia-vue3 version: 0.3.5

Describe the problem:

Using persistent layouts gives the following error:

Error: Codegen node is missing for element/if/for node. Apply appropriate transforms first.

Steps to reproduce:

Switch from the layout component used in template to layout defined in component object.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
reininkcommented, Mar 1, 2021

Wait, I see the issue here. You’re using named slots. See #171.

If you need named slots, you’ll need to use regular layouts, not persistent layouts. Feel free to join in the discussion in the existing issue.

Closing this, as it’s a duplicate.

1reaction
reininkcommented, Mar 1, 2021

@buismaarten This appears to be the working code (it’s not using persistent layouts). Can you share the code that doesn’t work?

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to use Persistent Layouts with Inertia and Vue 3 Setup ...
Here's a quick way you can support persistent layouts with Vue 3's `setup` script syntax.
Read more >
vuejs3 - How can I reload a persistent layout or watch props ...
I have a Laravel project with InertiaJs and Vue3. I have a navigation as a persistent layout which works as expected.
Read more >
Pages - Inertia.js
Persistent layouts ​​ While it's simple to implement layouts as children of the page components, it does force the layout instance to be...
Read more >
Persistent Layout in Breeze/Vue - Laracasts
I'm using Laravel Breeze/Vue and I'm confused about something. In episode 12 (Persistent Layouts) of 'Building Modern Laravel Apps using Inertia.js', ...
Read more >
Vue tricks: smart layouts for VueJS | by Manu Ustenko - ITNEXT
First of all, remove HelloWorld.vue component and components folder. In this project it won't be needed. In Home.vue we should remove import to ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found