rsnext/packages
Zack Tanner 6f74618486
Guard against restoring router state with missing data (#61822)
Unclear when this can happen currently (hence missing a test), but this adds a safeguard to `applyUrlFromHistoryPushReplace` to ensure that we don't potentially call `ACTION_RESTORE` with data that might be missing from `window.history.state`. 

This is consistent with other spots where we're reading this internal flag from state.

The function that calls `applyUrlFromHistoryPushReplace` first calls `copyNextJsInternalHistoryState` to copy over `__PRIVATE_NEXTJS_INTERNALS_TREE` into the data argument of `pushState`/`replaceState`.  But technically it does so with the possibility that `__PRIVATE_NEXTJS_INTERNALS_TREE` is undefined. Since that's the case, this is more typesafe. 

Closes NEXT-2406
2024-02-08 09:28:23 -08:00
..
create-next-app v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
eslint-config-next v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
eslint-plugin-next v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
font v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next Guard against restoring router state with missing data (#61822) 2024-02-08 09:28:23 -08:00
next-bundle-analyzer v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-codemod v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-env v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-mdx v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-plugin-storybook v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-polyfill-module v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-polyfill-nomodule v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
next-swc feat: Allow specifying useLightningcss for styled-jsx (#61359) 2024-02-08 17:05:29 +01:00
react-dev-overlay DX: fix error overlay flash (#61813) 2024-02-08 16:54:01 +01:00
react-refresh-utils v14.1.1-canary.44 2024-02-08 12:22:09 +00:00
third-parties v14.1.1-canary.44 2024-02-08 12:22:09 +00:00