Adding new component(page)
how to add new pages (components) in the LaravelVue version?
i want the pages that i add to include the theme elements like the sidebar
Did you follow our Laraavel integration doc or it is your own integration?
I follow your documentations and there is nothing about adding a new page in vue version
Then adding a new page should look the same as in the standard vue app.
- Add your page content component in /views folder.
- Register new route in file router/index.ts.
component: () => import("@/views/NamOfYourPageComponent.vue"),
the problem is when i create a new component it doesn't extend from the default layout as the other components
in router/index.ts file, you need regist component
as child of Layout
component: () => import("@/layout/Layout.vue"),
Yes, as is mentioned in the comment above, to use the default layout you have to register a new route as a child of the Layout in router/index.ts.