Skip to content

[docs] clarification on how data resolves keys with the same name #13398

Open
@sacrosanctic

Description

@sacrosanctic

Describe the bug

If multiple load functions return data with the same key, the last one ‘wins’
https://svelte.dev/docs/kit/load#Layout-data

Q1: What does "last one" mean? how are load functions ordered? This is confusing as another section mentions that they run in parallel.


Q2: Are load functions ordered differently during SSR vs CSR. Are the following statements correct?

  • In SSR, all load functions run in parallel
  • In CSR, all server load functions then all universal load functions

Reproduction

.

Logs

System Info

.

Severity

annoyance

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions