-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
Multi-page mode example #257
Comments
SSR feels like PHP again... generating content e.g. head tag information on the server site... If it is a multi page static site (not sure about SSR), from what I know,..
|
Regardless of SSR, multi-page is something Vite does plan to support. |
There is a simple demo by @posva here of vue with vue-router, but that doesn't handle generation of all entry points. i.e |
Is there any update on this? |
Also interested if there's an update. Thanks. |
+1 |
Hey guys.The 2.0 support this feature. Please see https://vitejs.dev/guide/build.html#multi-page-app |
I have an issue with the way vite handle this. I have a build like this : rollupOptions: {
input: {
app: resolve(__dirname, 'assets/app.js'),
admin: resolve(__dirname, 'assets/admin.js')
}
}, I'm expecting 2 file in the output : app.js and admin.js but I end up with 3 files
I guess Modal contains the code shared between the 2 files but in some case we may want vite to compile these 2 entry point as separate files (without the share libraries file). |
I guess the current implementation is wrong. What if I have 50+ pages, I have to mention every page in (I'm using Vanilla JS) |
@surjithctly see vite-plugin-mpa. Anyway, do not write on closed issues since ppl just ignore it. |
This issue has been locked since it has been closed for more than 14 days. If you have found a concrete bug or regression related to it, please open a new bug report with a reproduction against the latest Vite version. If you have any other comments you should join the chat at Vite Land or create a new discussion. |
Is your feature request related to a problem? Please describe.
I'm trying to get Vue3 + Vite working in multi-page mode.
Describe the solution you'd like
An example of how to use vite to build a multi-paged app, much like the
pages
option in the Vue CLI Config Reference.Describe alternatives you've considered
I tried looking through the source to see if I could spot how this could be accomplished, but didn't find anything obvious I could try.
Additional context
I'm investigating using Vue3 + Vite to replace an existing Nuxt SSR solution, but perhaps the best answer here is to wait until things develop further to see which solutions emerge.
The text was updated successfully, but these errors were encountered: