Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default Layout for eager: false / code-splitting #279

Open
dinyo opened this issue Jan 19, 2023 · 0 comments
Open

Default Layout for eager: false / code-splitting #279

dinyo opened this issue Jan 19, 2023 · 0 comments

Comments

@dinyo
Copy link

dinyo commented Jan 19, 2023

The default layouts section (in Pages) not covering eager: false / code-splitting case

example for vue 3 (https://stackoverflow.com/a/72867218):

import Layout from './Layout'

createInertiaApp({
  resolve: name => {
        const page = resolvePageComponent(`./Pages/${name}.vue`, import.meta.glob('./Pages/**/*.vue'))
        page.then((p) => {
            p.default.layout = p.default.layout || Layout
        })
        return page
  },
  // ...
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant