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

SSG generates useless files #26

Closed
ctholho opened this issue May 18, 2021 · 2 comments · Fixed by #27
Closed

SSG generates useless files #26

ctholho opened this issue May 18, 2021 · 2 comments · Fixed by #27

Comments

@ctholho
Copy link
Contributor

ctholho commented May 18, 2021

As mentioned at issue #119 of vitesse, vite-ssg will generate unnecessary files.

Using path: '' for children components in a nested router solves this (see docs)

With one caveat: when the router has a nested route before using setupLayouts(). So we have to traverse the path ourselves.

@JohnCampionJr
Copy link
Owner

I haven't done much with SSG, but I'm happy to merge the PR once you're satisfied with it

@ctholho
Copy link
Contributor Author

ctholho commented May 19, 2021

If my PR at vite-ssg is accepted this wouldn't be necessary anymore and to merge or not is your esthetical choice.

Technically you can use either: a child component with /exact/same/route/as/parent or an empty string ''. vite-plugin-pages uses the latter.

@ctholho ctholho closed this as completed May 26, 2021
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

Successfully merging a pull request may close this issue.

2 participants