Skip to content

Commit

Permalink
Merge branch 'dev' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
markdalgleish authored Jul 29, 2024
2 parents 07b446f + 1ac5c50 commit c037716
Show file tree
Hide file tree
Showing 94 changed files with 1,240 additions and 1,866 deletions.
9 changes: 9 additions & 0 deletions .changeset/add-unstable-data.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@remix-run/cloudflare": minor
"@remix-run/deno": minor
"@remix-run/node": minor
"@remix-run/react": minor
"@remix-run/server-runtime": minor
---

Add a new `unstable_data()` API for usage with Remix Single Fetch
9 changes: 9 additions & 0 deletions .changeset/curvy-vans-remember.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@remix-run/cloudflare": minor
"@remix-run/deno": minor
"@remix-run/node": minor
"@remix-run/react": minor
"@remix-run/server-runtime": minor
---

Add a new `replace(url, init?)` alternative to `redirect(url, init?)` that performs a `history.replaceState` instead of a `history.pushState` on client-side navigation redirects
5 changes: 0 additions & 5 deletions .changeset/cyan-dingos-report.md

This file was deleted.

8 changes: 8 additions & 0 deletions .changeset/happy-dots-sleep.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
"@remix-run/dev": minor
"@remix-run/react": minor
"@remix-run/server-runtime": minor
"@remix-run/testing": minor
---

Rename `future.unstable_fogOfWar` to `future.unstable_lazyRouteDiscovery` for clarity
5 changes: 5 additions & 0 deletions .changeset/large-donkeys-remember.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@remix-run/react": patch
---

Ensure single fetch calls don't include any trailing slash from the pathname (i.e., /path/.data)
25 changes: 25 additions & 0 deletions .changeset/remove-response-stub.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
"@remix-run/server-runtime": minor
"@remix-run/react": minor
---

Single Fetch: Remove `responseStub` in favor of `headers`

- Background

- The original Single Fetch approach was based on an assumption that an eventual `middleware` implementation would require something like `ResponseStub` so users could mutate `status`/`headers` in `middleware` before/after handlers as well as during handlers
- We wanted to align how `headers` got merged between document and data requests
- So we made document requests also use `ResponseStub` and removed the usage of `headers` in Single Fetch
- The realization/alignment between Michael and Ryan on the recent [roadmap planning](https://www.youtube.com/watch?v=f5z_axCofW0) made us realize that the original assumption was incorrect
- `middleware` won't need a stub - users can just mutate the `Response` they get from `await next()` directly
- With that gone, and still wanting to align how `headers` get merged, it makes more sense to stick with the current `headers` API and apply that to Single Fetch and avoid introducing a totally new thing in `RepsonseStub` (that always felt a bit awkward to work with anyway)

- With this change:
- You are encouraged to stop returning `Response` instances in favor of returning raw data from loaders and actions:
- ~~`return json({ data: whatever });`~~
- `return { data: whatever };`
- In most cases, you can remove your `json()` and `defer()` calls in favor of returning raw data if they weren't setting custom `status`/`headers`
- We will be removing both `json` and `defer` in the next major version, but both _should_ still work in Single Fetch in v2 to allow for incremental adoption of the new behavior
- If you need custom `status`/`headers`:
- We've added a new `unstable_data({...}, responseInit)` utility that will let you send back `status`/`headers` alongside your raw data without having to encode it into a `Response`
- The `headers()` function will let you control header merging for both document and data requests
6 changes: 6 additions & 0 deletions .changeset/tender-elephants-kneel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@remix-run/react": patch
"@remix-run/server-runtime": patch
---

- Change initial hydration route mismatch from a URL check to a matches check to be resistant to URL inconsistenceis
5 changes: 0 additions & 5 deletions .changeset/young-hairs-hug.md

This file was deleted.

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

- [Remix Releases](#remix-releases)
- [v2.10.1](#v2101)
- [v2.10.3](#v2103)
- [Patch Changes](#patch-changes)
- [Updated Dependencies](#updated-dependencies)
- [Changes by Package](#changes-by-package)
- [v2.10.2](#v2102)
- [Patch Changes](#patch-changes-1)
- [Changes by Package](#changes-by-package-1)
- [v2.10.1](#v2101)
- [Patch Changes](#patch-changes-2)
- [Updated Dependencies](#updated-dependencies-1)
- [Changes by Package](#changes-by-package-2)
- [v2.10.0](#v2100)
- [What's Changed](#whats-changed)
- [Lazy Route Discovery (a.k.a. "Fog of War")](#lazy-route-discovery-aka-fog-of-war)
- [Minor Changes](#minor-changes)
- [Patch Changes](#patch-changes-1)
- [Updated Dependencies](#updated-dependencies-1)
- [Changes by Package](#changes-by-package-1)
- [Patch Changes](#patch-changes-3)
- [Updated Dependencies](#updated-dependencies-2)
- [Changes by Package](#changes-by-package-3)
- [v2.9.2](#v292)
- [What's Changed](#whats-changed-1)
- [Updated Type-Safety for Single Fetch](#updated-type-safety-for-single-fetch)
- [Patch Changes](#patch-changes-2)
- [Updated Dependencies](#updated-dependencies-2)
- [Changes by Package](#changes-by-package-2)
- [Patch Changes](#patch-changes-4)
- [Updated Dependencies](#updated-dependencies-3)
- [Changes by Package](#changes-by-package-4)
- [v2.9.1](#v291)
- [Patch Changes](#patch-changes-3)
- [Changes by Package](#changes-by-package-3)
- [Patch Changes](#patch-changes-5)
- [Changes by Package](#changes-by-package-5)
- [v2.9.0](#v290)
- [What's Changed](#whats-changed-2)
- [Single Fetch (unstable)](#single-fetch-unstable)
- [Undici](#undici)
- [Minor Changes](#minor-changes-1)
- [Patch Changes](#patch-changes-4)
- [Updated Dependencies](#updated-dependencies-3)
- [Changes by Package](#changes-by-package-4)
- [v2.8.1](#v281)
- [Patch Changes](#patch-changes-5)
- [Patch Changes](#patch-changes-6)
- [Updated Dependencies](#updated-dependencies-4)
- [Changes by Package](#changes-by-package-5)
- [Changes by Package](#changes-by-package-6)
- [v2.8.1](#v281)
- [Patch Changes](#patch-changes-7)
- [Updated Dependencies](#updated-dependencies-5)
- [Changes by Package](#changes-by-package-7)
- [v2.8.0](#v280)
- [Minor Changes](#minor-changes-2)
- [Patch Changes](#patch-changes-6)
- [Updated Dependencies](#updated-dependencies-5)
- [Changes by Package](#changes-by-package-6)
- [Patch Changes](#patch-changes-8)
- [Updated Dependencies](#updated-dependencies-6)
- [Changes by Package](#changes-by-package-8)
- [2.7.2](#272)
- [Patch Changes](#patch-changes-7)
- [Patch Changes](#patch-changes-9)
- [2.7.1](#271)
- [Patch Changes](#patch-changes-8)
- [Patch Changes](#patch-changes-10)
- [v2.7.0](#v270)
- [What's Changed](#whats-changed-3)
- [Stabilized Vite Plugin](#stabilized-vite-plugin)
- [New `Layout` Export](#new-layout-export)
- [Basename support](#basename-support)
- [Cloudflare Proxy as a Vite Plugin](#cloudflare-proxy-as-a-vite-plugin)
- [Minor Changes](#minor-changes-3)
- [Patch Changes](#patch-changes-9)
- [Updated Dependencies](#updated-dependencies-6)
- [Changes by Package](#changes-by-package-7)
- [Patch Changes](#patch-changes-11)
- [Updated Dependencies](#updated-dependencies-7)
- [Changes by Package](#changes-by-package-9)
- [v2.6.0](#v260)
- [What's Changed](#whats-changed-4)
- [Unstable Vite Plugin updates](#unstable-vite-plugin-updates)
- [Minor Changes](#minor-changes-4)
- [Patch Changes](#patch-changes-10)
- [Updated Dependencies](#updated-dependencies-7)
- [Changes by Package](#changes-by-package-8)
- [v2.5.1](#v251)
- [Patch Changes](#patch-changes-11)
- [Patch Changes](#patch-changes-12)
- [Updated Dependencies](#updated-dependencies-8)
- [Changes by Package](#changes-by-package-9)
- [Changes by Package](#changes-by-package-10)
- [v2.5.1](#v251)
- [Patch Changes](#patch-changes-13)
- [Updated Dependencies](#updated-dependencies-9)
- [Changes by Package](#changes-by-package-11)
- [v2.5.0](#v250)
- [What's Changed](#whats-changed-5)
- [SPA Mode (unstable)](#spa-mode-unstable)
- [Server Bundles (unstable)](#server-bundles-unstable)
- [Minor Changes](#minor-changes-5)
- [Patch Changes](#patch-changes-12)
- [Updated Dependencies](#updated-dependencies-9)
- [Changes by Package](#changes-by-package-10)
- [v2.4.1](#v241)
- [Patch Changes](#patch-changes-13)
- [Patch Changes](#patch-changes-14)
- [Updated Dependencies](#updated-dependencies-10)
- [Changes by Package](#changes-by-package-11)
- [Changes by Package](#changes-by-package-12)
- [v2.4.1](#v241)
- [Patch Changes](#patch-changes-15)
- [Updated Dependencies](#updated-dependencies-11)
- [Changes by Package](#changes-by-package-13)
- [v2.4.0](#v240)
- [What's Changed](#whats-changed-6)
- [Client Data](#client-data)
- [`future.v3_relativeSplatPath`](#futurev3_relativesplatpath)
- [Vite Updates (Unstable)](#vite-updates-unstable)
- [Minor Changes](#minor-changes-6)
- [Patch Changes](#patch-changes-14)
- [Updated Dependencies](#updated-dependencies-11)
- [Changes by Package](#changes-by-package-12)
- [v2.3.1](#v231)
- [Patch Changes](#patch-changes-15)
- [Patch Changes](#patch-changes-16)
- [Updated Dependencies](#updated-dependencies-12)
- [Changes by Package](#changes-by-package-13)
- [Changes by Package](#changes-by-package-14)
- [v2.3.1](#v231)
- [Patch Changes](#patch-changes-17)
- [Updated Dependencies](#updated-dependencies-13)
- [Changes by Package](#changes-by-package-15)
- [v2.3.0](#v230)
- [What's Changed](#whats-changed-7)
- [Stabilized `useBlocker`](#stabilized-useblocker)
- [`unstable_flushSync` API](#unstable_flushsync-api)
- [Minor Changes](#minor-changes-7)
- [Patch Changes](#patch-changes-16)
- [Updated Dependencies](#updated-dependencies-13)
- [Changes by Package](#changes-by-package-14)
- [Patch Changes](#patch-changes-18)
- [Updated Dependencies](#updated-dependencies-14)
- [Changes by Package](#changes-by-package-16)
- [v2.2.0](#v220)
- [What's Changed](#whats-changed-8)
- [Vite!](#vite)
- [New Fetcher APIs](#new-fetcher-apis)
- [Persistence Future Flag](#persistence-future-flag)
- [Minor Changes](#minor-changes-8)
- [Patch Changes](#patch-changes-17)
- [Updated Dependencies](#updated-dependencies-14)
- [Changes by Package](#changes-by-package-15)
- [Patch Changes](#patch-changes-19)
- [Updated Dependencies](#updated-dependencies-15)
- [Changes by Package](#changes-by-package-17)
- [v2.1.0](#v210)
- [What's Changed](#whats-changed-9)
- [View Transitions](#view-transitions)
- [Stable `createRemixStub`](#stable-createremixstub)
- [Minor Changes](#minor-changes-9)
- [Patch Changes](#patch-changes-18)
- [Updated Dependencies](#updated-dependencies-15)
- [Changes by Package](#changes-by-package-16)
- [Patch Changes](#patch-changes-20)
- [Updated Dependencies](#updated-dependencies-16)
- [Changes by Package](#changes-by-package-18)
- [v2.0.1](#v201)
- [Patch Changes](#patch-changes-19)
- [Patch Changes](#patch-changes-21)
- [Changes by Package 🔗](#changes-by-package-)
- [v2.0.0](#v200)
- [Breaking Changes](#breaking-changes)
Expand All @@ -138,8 +145,8 @@ We manage release notes in this file instead of the paginated Github Releases Pa
- [Breaking Type Changes](#breaking-type-changes)
- [New Features](#new-features)
- [Other Notable Changes](#other-notable-changes)
- [Updated Dependencies](#updated-dependencies-16)
- [Changes by Package](#changes-by-package-17)
- [Updated Dependencies](#updated-dependencies-17)
- [Changes by Package](#changes-by-package-19)

</details>

Expand Down Expand Up @@ -187,6 +194,73 @@ Date: YYYY-MM-DD
-->

## v2.10.3

Date: 2024-07-16

### Patch Changes

- `@remix-run/architect` - Manually joining headers with semi-colons to avoid differences in Remix and node/undici Headers implementation ([#9664](https://github.com/remix-run/remix/pull/9664))
- `@remix-run/react` - Log any errors encountered loading a route module prior to reloading the page ([#8932](https://github.com/remix-run/remix/pull/8932))
- `@remix-run/react` - Single Fetch (unstable): Proxy `request.signal` through `dataStrategy` for `loader` calls to fix cancellation ([#9738](https://github.com/remix-run/remix/pull/9738))
- `@remix-run/react` - Single Fetch (unstable): Adopt React Router's stabilized `future.v7_skipActionErrorRevalidation` under the hood ([#9706](https://github.com/remix-run/remix/pull/9706))
- This stabilizes the `shouldRevalidate` parameter from `unstable_actionStatus` to `actionStatus`
- ⚠️ This might be a breaking change for your app if you have opted into single fetch and the `unstable_actionStatus` parameter

### Updated Dependencies

- [`[email protected]`](https://github.com/remix-run/react-router/releases/tag/react-router%406.25.0)
- [`@remix-run/[email protected]`](https://github.com/remix-run/react-router/blob/main/packages/router/CHANGELOG.md#1180)

### Changes by Package

- [`create-remix`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/create-remix/CHANGELOG.md#2103)
- [`@remix-run/architect`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-architect/CHANGELOG.md#2103)
- [`@remix-run/cloudflare`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-cloudflare/CHANGELOG.md#2103)
- [`@remix-run/cloudflare-pages`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-cloudflare-pages/CHANGELOG.md#2103)
- [`@remix-run/cloudflare-workers`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-cloudflare-workers/CHANGELOG.md#2103)
- [`@remix-run/css-bundle`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-css-bundle/CHANGELOG.md#2103)
- [`@remix-run/deno`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-deno/CHANGELOG.md#2103)
- [`@remix-run/dev`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-dev/CHANGELOG.md#2103)
- [`@remix-run/eslint-config`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-eslint-config/CHANGELOG.md#2103)
- [`@remix-run/express`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-express/CHANGELOG.md#2103)
- [`@remix-run/node`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-node/CHANGELOG.md#2103)
- [`@remix-run/react`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-react/CHANGELOG.md#2103)
- [`@remix-run/serve`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-serve/CHANGELOG.md#2103)
- [`@remix-run/server-runtime`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-server-runtime/CHANGELOG.md#2103)
- [`@remix-run/testing`](https://github.com/remix-run/remix/blob/remix%402.10.3/packages/remix-testing/CHANGELOG.md#2103)

**Full Changelog**: [`v2.10.2...v2.10.3`](https://github.com/remix-run/remix/compare/[email protected]@2.10.3)

## v2.10.2

Date: 2024-07-04

### Patch Changes

- `@remix-run/react` - Forward `ref` to `Form` ([`bdd04217`](https://github.com/remix-run/remix/commit/bdd04217713292307078a30dab9033926d48ede6))
- `@remix-run/server-runtime` - Fix bug with `immutable` headers on raw native `fetch` responses returned from loaders ([#9693](https://github.com/remix-run/remix/pull/9693))

### Changes by Package

- [`create-remix`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/create-remix/CHANGELOG.md#2102)
- [`@remix-run/architect`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-architect/CHANGELOG.md#2102)
- [`@remix-run/cloudflare`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-cloudflare/CHANGELOG.md#2102)
- [`@remix-run/cloudflare-pages`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-cloudflare-pages/CHANGELOG.md#2102)
- [`@remix-run/cloudflare-workers`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-cloudflare-workers/CHANGELOG.md#2102)
- [`@remix-run/css-bundle`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-css-bundle/CHANGELOG.md#2102)
- [`@remix-run/deno`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-deno/CHANGELOG.md#2102)
- [`@remix-run/dev`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-dev/CHANGELOG.md#2102)
- [`@remix-run/eslint-config`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-eslint-config/CHANGELOG.md#2102)
- [`@remix-run/express`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-express/CHANGELOG.md#2102)
- [`@remix-run/node`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-node/CHANGELOG.md#2102)
- [`@remix-run/react`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-react/CHANGELOG.md#2102)
- [`@remix-run/serve`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-serve/CHANGELOG.md#2102)
- [`@remix-run/server-runtime`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-server-runtime/CHANGELOG.md#2102)
- [`@remix-run/testing`](https://github.com/remix-run/remix/blob/remix%402.10.2/packages/remix-testing/CHANGELOG.md#2102)

**Full Changelog**: [`v2.10.1...v2.10.2`](https://github.com/remix-run/remix/compare/[email protected]@2.10.2)

## v2.10.1

Date: 2024-07-03
Expand Down
6 changes: 6 additions & 0 deletions contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
- abotsi
- accidentaldeveloper
- achinchen
- acusti
- adamwathan
- adicuco
- AdiRishi
Expand Down Expand Up @@ -83,6 +84,7 @@
- bogas04
- BogdanDevBst
- bolchowka
- brettscott
- brookslybrand
- brophdawg11
- bruno-oliveira
Expand Down Expand Up @@ -115,6 +117,7 @@
- colinhacks
- confix
- coryhouse
- courey
- courtyenn
- craigayre
- craigglennie
Expand Down Expand Up @@ -230,6 +233,7 @@
- gustavoguichard
- gustavopch
- gyx1000
- hadimalikdev
- hadizz
- haines
- hardingmatt
Expand Down Expand Up @@ -428,6 +432,7 @@
- MatthewAlbrecht
- matthova
- Mattinton
- mattkindy
- mattmazzola
- mattstobbs
- maxprilutskiy
Expand Down Expand Up @@ -573,6 +578,7 @@
- sean-roberts
- SeanGroff
- SeanRoberts
- sebastien-comeau
- sebz
- selfish
- sergiocarneiro
Expand Down
Loading

0 comments on commit c037716

Please sign in to comment.