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

Misleading static adapter manual #8396

Closed
pboguslawski opened this issue Jan 8, 2023 · 0 comments · Fixed by #8502
Closed

Misleading static adapter manual #8396

pboguslawski opened this issue Jan 8, 2023 · 0 comments · Fixed by #8502
Labels
documentation Improvements or additions to documentation help wanted PRs welcomed. The implementation details are unlikely to cause debate

Comments

@pboguslawski
Copy link

Describe the bug

According to https://github.com/sveltejs/kit/tree/master/packages/adapter-static#sveltejsadapter-static

Adapter for SvelteKit apps that prerenders your entire site as a collection of static files. If you'd like to prerender only some pages, you will need to use a different adapter together with [the prerender option] (https://kit.svelte.dev/docs/page-options#prerender).

According to https://github.com/sveltejs/kit/tree/master/packages/adapter-static#turn-off-prerendering

When operating in SPA mode, you can omit the prerender option from your root layout (or set it to false, its default value), and only pages that have the prerender option set will be prerendered at build time.
[...]
You can also add turn off prerendering only to parts of your app, if you want other parts to be prerendered.

Practical tests (sveltekit v1) show, that using adapter-static with prerendering only some of pages works ok (i.e. when only CSR is used and some of pages use URL params, it cannot be prerendered probably but works fine with fallback page configured). If it is supported officially adapter-static manual should probably be updated (and conflicting information mentioned above should be removed).

Reproduction

Read manual.

Logs

No response

System Info

any

Severity

annoyance

Additional Information

No response

@Rich-Harris Rich-Harris added the documentation Improvements or additions to documentation label Jan 8, 2023
@dummdidumm dummdidumm added the help wanted PRs welcomed. The implementation details are unlikely to cause debate label Jan 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation help wanted PRs welcomed. The implementation details are unlikely to cause debate
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants