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

[legacy-framework] Fix dehydrateState does not apply server side props #2617

Merged
merged 3 commits into from
Aug 11, 2021

Commits on Jul 31, 2021

  1. Fixes dehydrate state SSR

    Cody George committed Jul 31, 2021
    Configuration menu
    Copy the full SHA
    14d91c1 View commit details
    Browse the repository at this point in the history
  2. rm file

    Cody George committed Jul 31, 2021
    Configuration menu
    Copy the full SHA
    90cdd1a View commit details
    Browse the repository at this point in the history

Commits on Aug 3, 2021

  1. Deserialize dehydratedState

    Before, it just said `SuperJSON.deserialize(props.pageProps.dehydratedState)`. This didn't work since it doesn't account for babel-plugin-superjson-next to pick different superjson keys than SuperJSON itself :( SuperJSON expects a `json` and a `meta` key, while babel-plugin-superjson-next puts the meta right into the props and calls it `_superjson`. This commit fixes that behaviour, and makes sure that dehydratedState works both for SSR and for client-side.
    Skn0tt committed Aug 3, 2021
    Configuration menu
    Copy the full SHA
    98bdcf8 View commit details
    Browse the repository at this point in the history