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

Collapse Packages #11505

Merged
merged 25 commits into from
Apr 30, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
46a7218
Collapse react-router-dom into react-router
brophdawg11 Apr 19, 2024
1535a5e
Move router code into react-router
brophdawg11 Apr 23, 2024
cd7efe0
Update imports
brophdawg11 Apr 23, 2024
1ce18de
Get react router tests passing
brophdawg11 Apr 23, 2024
96bcde0
Merge branch 'v7' into brophdawg11/collapse-packages
brophdawg11 Apr 23, 2024
94dfaa1
Remove packages from publish/version scripts
brophdawg11 Apr 23, 2024
0c0d02a
Move single fetch shared types into RR
brophdawg11 Apr 25, 2024
5d9abd7
Fix react router importing from itself
brophdawg11 Apr 25, 2024
95bdcd3
Get rollup build working
brophdawg11 Apr 25, 2024
4cdf693
Remove remix run testing package
brophdawg11 Apr 25, 2024
cdfdaee
Add changeset
brophdawg11 Apr 25, 2024
148dbc6
Fix unit tests
brophdawg11 Apr 26, 2024
83e668e
Add back react-router-dom package for re-exports
brophdawg11 Apr 26, 2024
51cf326
Fix integration tests
brophdawg11 Apr 26, 2024
f629cbc
Fix TS and lint issues
brophdawg11 Apr 26, 2024
804f638
Remove from bundle check
brophdawg11 Apr 26, 2024
38a590e
Set bundle sizes for new collapsed package
brophdawg11 Apr 26, 2024
8adfe08
Update experimental flow to use correct token
brophdawg11 Apr 26, 2024
ca313db
Update version script
brophdawg11 Apr 26, 2024
53924e4
Update version script
brophdawg11 Apr 26, 2024
348eecf
Temporrily remove publish from workflow
brophdawg11 Apr 26, 2024
e53172d
Update meta info in package.json prior to experimental publish
brophdawg11 Apr 26, 2024
c085628
Add new @react-router packages to publish script
brophdawg11 Apr 26, 2024
7b411a7
Add startTransition back to RouterPRovider for v7
brophdawg11 Apr 29, 2024
f1233ec
Merge branch 'v7' into brophdawg11/collapse-packages
brophdawg11 Apr 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch 'v7' into brophdawg11/collapse-packages
  • Loading branch information
brophdawg11 committed Apr 23, 2024
commit 96bcde0f7ae62aa0e7dc9544abe52ae9965f3199
8 changes: 0 additions & 8 deletions .changeset/data-strategy.md

This file was deleted.

11 changes: 0 additions & 11 deletions .changeset/skip-action-revalidation.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/slow-flies-help.md

This file was deleted.

8 changes: 0 additions & 8 deletions .changeset/static-query-flags.md

This file was deleted.

99 changes: 65 additions & 34 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,21 @@ We manage release notes in this file instead of the paginated Github Releases Pa
<summary>Table of Contents</summary>

- [React Router Releases](#react-router-releases)
- [v6.23.0](#v6230)
- [What's Changed](#whats-changed)
- [Data Strategy (unstable)](#data-strategy-unstable)
- [Skip Action Error Revalidation (unstable)](#skip-action-error-revalidation-unstable)
- [Minor Changes](#minor-changes)
- [v6.22.3](#v6223)
- [Patch Changes](#patch-changes)
- [v6.22.2](#v6222)
- [Patch Changes](#patch-changes-1)
- [v6.22.1](#v6221)
- [Patch Changes](#patch-changes-2)
- [v6.22.0](#v6220)
- [What's Changed](#whats-changed)
- [What's Changed](#whats-changed-1)
- [Core Web Vitals Technology Report Flag](#core-web-vitals-technology-report-flag)
- [Minor Changes](#minor-changes)
- [Minor Changes](#minor-changes-1)
- [Patch Changes](#patch-changes-3)
- [v6.21.3](#v6213)
- [Patch Changes](#patch-changes-4)
Expand All @@ -31,96 +36,96 @@ We manage release notes in this file instead of the paginated Github Releases Pa
- [v6.21.1](#v6211)
- [Patch Changes](#patch-changes-6)
- [v6.21.0](#v6210)
- [What's Changed](#whats-changed-1)
- [What's Changed](#whats-changed-2)
- [`future.v7_relativeSplatPath`](#futurev7_relativesplatpath)
- [Partial Hydration](#partial-hydration)
- [Minor Changes](#minor-changes-1)
- [Minor Changes](#minor-changes-2)
- [Patch Changes](#patch-changes-7)
- [v6.20.1](#v6201)
- [Patch Changes](#patch-changes-8)
- [v6.20.0](#v6200)
- [Minor Changes](#minor-changes-2)
- [Minor Changes](#minor-changes-3)
- [Patch Changes](#patch-changes-9)
- [v6.19.0](#v6190)
- [What's Changed](#whats-changed-2)
- [What's Changed](#whats-changed-3)
- [`unstable_flushSync` API](#unstable_flushsync-api)
- [Minor Changes](#minor-changes-3)
- [Minor Changes](#minor-changes-4)
- [Patch Changes](#patch-changes-10)
- [v6.18.0](#v6180)
- [What's Changed](#whats-changed-3)
- [What's Changed](#whats-changed-4)
- [New Fetcher APIs](#new-fetcher-apis)
- [Persistence Future Flag (`future.v7_fetcherPersist`)](#persistence-future-flag-futurev7_fetcherpersist)
- [Minor Changes](#minor-changes-4)
- [Minor Changes](#minor-changes-5)
- [Patch Changes](#patch-changes-11)
- [v6.17.0](#v6170)
- [What's Changed](#whats-changed-4)
- [What's Changed](#whats-changed-5)
- [View Transitions 🚀](#view-transitions-)
- [Minor Changes](#minor-changes-5)
- [Minor Changes](#minor-changes-6)
- [Patch Changes](#patch-changes-12)
- [v6.16.0](#v6160)
- [Minor Changes](#minor-changes-6)
- [Minor Changes](#minor-changes-7)
- [Patch Changes](#patch-changes-13)
- [v6.15.0](#v6150)
- [Minor Changes](#minor-changes-7)
- [Minor Changes](#minor-changes-8)
- [Patch Changes](#patch-changes-14)
- [v6.14.2](#v6142)
- [Patch Changes](#patch-changes-15)
- [v6.14.1](#v6141)
- [Patch Changes](#patch-changes-16)
- [v6.14.0](#v6140)
- [What's Changed](#whats-changed-5)
- [What's Changed](#whats-changed-6)
- [JSON/Text Submissions](#jsontext-submissions)
- [Minor Changes](#minor-changes-8)
- [Minor Changes](#minor-changes-9)
- [Patch Changes](#patch-changes-17)
- [v6.13.0](#v6130)
- [What's Changed](#whats-changed-6)
- [Minor Changes](#minor-changes-9)
- [What's Changed](#whats-changed-7)
- [Minor Changes](#minor-changes-10)
- [Patch Changes](#patch-changes-18)
- [v6.12.1](#v6121)
- [Patch Changes](#patch-changes-19)
- [v6.12.0](#v6120)
- [What's Changed](#whats-changed-7)
- [What's Changed](#whats-changed-8)
- [`React.startTransition` support](#reactstarttransition-support)
- [Minor Changes](#minor-changes-10)
- [Minor Changes](#minor-changes-11)
- [Patch Changes](#patch-changes-20)
- [v6.11.2](#v6112)
- [Patch Changes](#patch-changes-21)
- [v6.11.1](#v6111)
- [Patch Changes](#patch-changes-22)
- [v6.11.0](#v6110)
- [Minor Changes](#minor-changes-11)
- [Minor Changes](#minor-changes-12)
- [Patch Changes](#patch-changes-23)
- [v6.10.0](#v6100)
- [What's Changed](#whats-changed-8)
- [Minor Changes](#minor-changes-12)
- [What's Changed](#whats-changed-9)
- [Minor Changes](#minor-changes-13)
- [Patch Changes](#patch-changes-24)
- [v6.9.0](#v690)
- [What's Changed](#whats-changed-9)
- [What's Changed](#whats-changed-10)
- [`Component`/`ErrorBoundary` route properties](#componenterrorboundary-route-properties)
- [Introducing Lazy Route Modules](#introducing-lazy-route-modules)
- [Minor Changes](#minor-changes-13)
- [Minor Changes](#minor-changes-14)
- [Patch Changes](#patch-changes-25)
- [v6.8.2](#v682)
- [Patch Changes](#patch-changes-26)
- [v6.8.1](#v681)
- [Patch Changes](#patch-changes-27)
- [v6.8.0](#v680)
- [Minor Changes](#minor-changes-14)
- [Minor Changes](#minor-changes-15)
- [Patch Changes](#patch-changes-28)
- [v6.7.0](#v670)
- [Minor Changes](#minor-changes-15)
- [Minor Changes](#minor-changes-16)
- [Patch Changes](#patch-changes-29)
- [v6.6.2](#v662)
- [Patch Changes](#patch-changes-30)
- [v6.6.1](#v661)
- [Patch Changes](#patch-changes-31)
- [v6.6.0](#v660)
- [What's Changed](#whats-changed-10)
- [Minor Changes](#minor-changes-16)
- [Patch Changes](#patch-changes-32)
- [v6.5.0](#v650)
- [What's Changed](#whats-changed-11)
- [Minor Changes](#minor-changes-17)
- [Patch Changes](#patch-changes-32)
- [v6.5.0](#v650)
- [What's Changed](#whats-changed-12)
- [Minor Changes](#minor-changes-18)
- [Patch Changes](#patch-changes-33)
- [v6.4.5](#v645)
- [Patch Changes](#patch-changes-34)
Expand All @@ -133,22 +138,22 @@ We manage release notes in this file instead of the paginated Github Releases Pa
- [v6.4.1](#v641)
- [Patch Changes](#patch-changes-38)
- [v6.4.0](#v640)
- [What's Changed](#whats-changed-12)
- [What's Changed](#whats-changed-13)
- [Remix Data APIs](#remix-data-apis)
- [Patch Changes](#patch-changes-39)
- [v6.3.0](#v630)
- [Minor Changes](#minor-changes-18)
- [Minor Changes](#minor-changes-19)
- [v6.2.2](#v622)
- [Patch Changes](#patch-changes-40)
- [v6.2.1](#v621)
- [Patch Changes](#patch-changes-41)
- [v6.2.0](#v620)
- [Minor Changes](#minor-changes-19)
- [Minor Changes](#minor-changes-20)
- [Patch Changes](#patch-changes-42)
- [v6.1.1](#v611)
- [Patch Changes](#patch-changes-43)
- [v6.1.0](#v610)
- [Minor Changes](#minor-changes-20)
- [Minor Changes](#minor-changes-21)
- [Patch Changes](#patch-changes-44)
- [v6.0.2](#v602)
- [Patch Changes](#patch-changes-45)
Expand Down Expand Up @@ -177,6 +182,32 @@ Date: YYYY-MM-DD
**Full Changelog**: [`v6.X.Y...v6.X.Y`](/~https://github.com/remix-run/react-router/compare/react-router@6.X.Y...react-router@6.X.Y)
-->

## v6.23.0

Date: 2024-04-23

### What's Changed

#### Data Strategy (unstable)

The new `unstable_dataStrategy` API is a low-level API designed for advanced use-cases where you need to take control over the data strategy for your `loader`/`action` functions. The default implementation is today's behavior, to fetch all loaders in parallel, but this option allows users to implement more advanced data flows including Remix ["Single Fetch"](https://remix.run/docs/guides/single-fetch), user-land middleware/context APIs, automatic loader caching, and more. Please see the [docs](https://reactrouter.com/routers/create-browser-router#unstable_datastrategy) for more information.

**Note:** This is a low-level API intended for advanced use-cases. This overrides React Router's internal handling of `loader`/`action` execution, and if done incorrectly will break your app code. Please use with caution and perform the appropriate testing.

#### Skip Action Error Revalidation (unstable)

Currently, all active `loader`'s revalidate after any `action` submission, regardless of the `action` result. However, in the majority of cases a `4xx`/`5xx` response from an `action` means that no data was actually changed and the revalidation is unnecessary. We've introduced a new `future.unstable_skipActionErrorRevalidation` flag that changes the behavior here, and we plan to make this the default in future version of React Router.

With this flag enabled, `action`'s that return/throw a `4xx`/`5xx` response status will no longer automatically revalidate. If you need to revalidate after a `4xx`/`5xx` result with this flag enabled, you can still do that via returning `true` from `shouldRevalidate` - which now also receives a new `unstable_actionStatus` argument alongside `actionResult` so you can make decision based on the status of the `action` response without having to encode it into the action data.

### Minor Changes

- Add a new `unstable_dataStrategy` configuration option ([#11098](/~https://github.com/remix-run/react-router/pull/11098), [#11377](/~https://github.com/remix-run/react-router/pull/11377))
- `@remix-run/router` - Add a new `future.unstable_skipActionRevalidation` future flag ([#11098](/~https://github.com/remix-run/react-router/pull/11098))
- `@remix-run/router` - SSR: Added a new `skipLoaderErrorBubbling` options to the `staticHandler.query` method to disable error bubbling by the static handler for use in Remix's Single Fetch implementation ([#11098](/~https://github.com/remix-run/react-router/pull/11098), ([#11377](/~https://github.com/remix-run/react-router/pull/11377)))

**Full Changelog**: [`v6.22.3...v6.23.0`](/~https://github.com/remix-run/react-router/compare/react-router@6.22.3...react-router@6.23.0)

## v6.22.3

Date: 2024-03-07
Expand Down
1 change: 1 addition & 0 deletions contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
- abeadam
- abhi-kr-2100
- AchThomas
- acusti
- adamdotjs
- adil62
- adriananin
Expand Down
2 changes: 1 addition & 1 deletion docs/hooks/use-navigate.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ new URL("..", window.origin + location.pathname);

// With trailing slashes:
new URL(".", window.origin + location.pathname + "/");
// 'https://remix.run/docs/en/main/start/future-flags/'
// 'https://remix.run/docs/en/main/start/quickstart/'
new URL("..", window.origin + location.pathname + "/");
// 'https://remix.run/docs/en/main/start/'
```
Expand Down
8 changes: 4 additions & 4 deletions docs/route/should-revalidate.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ This function allows you opt-out of revalidation for a route's [loader][loader]

There are several instances where data is revalidated, keeping your UI in sync with your data automatically:

- After an [`action`][action] is called from a [`<Form>`][form].
- After an [`action`][action] is called from a [`<fetcher.Form>`][fetcher]
- After an [`action`][action] is called from [`useSubmit`][usesubmit]
- After an [`action`][action] is called from a [`fetcher.submit`][fetcher]
- After an [`action`][action] is called via:
- [`<Form>`][form], [`<fetcher.Form>`][fetcher], [`useSubmit`][usesubmit], or [`fetcher.submit`][fetcher]
- When the `future.unstable_skipActionErrorRevalidation` flag is enabled, `loaders` will not revalidate by default if the `action` returns or throws a 4xx/5xx `Response`
- You can opt-into revalidation for these scenarios via `shouldRevalidate` and the `unstable_actionStatus` parameter
- When an explicit revalidation is triggered via [`useRevalidator`][userevalidator]
- When the [URL params][params] change for an already rendered route
- When the URL Search params change
Expand Down
Loading
You are viewing a condensed version of this merge commit. You can view the full changes here.