You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: GOVERNANCE.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -74,9 +74,12 @@ Due to the large number of React Router applications out there, we have to be a
74
74
75
75
## New Feature Process
76
76
77
-
The process for new features being added to React Router will follow a series of stages loosely based on the [TC39 Process](https://tc39.es/process-document/). It is important to note that entrance into any given stage does not imply that an RFC will proceed any further. The stages will act as a funnel with fewer RFCs making it into later stages such that only the strongest RFCs make it into a React Router release in a stable fashion. This table gives a high-level overview of the stages, but please see the individual stage sections below for more detailed information on the stages and the process for moving an FC through them.
77
+
The process for new features being added to React Router will follow a series of stages loosely based on the [TC39 Process](https://tc39.es/process-document/). It is important to note that entrance into any given stage does not imply that an RFC will proceed any further. The stages will act as a funnel with fewer RFCs making it into later stages such that only the strongest RFCs make it into a React Router release in a stable fashion.
78
78
79
-
Once a feature reaches Stage 2, it will be added to the [Roadmap](https://github.com/orgs/remix-run/projects/5) where it can be tracked as it moves through the stages.
79
+
> [!NOTE]
80
+
> Most new community-driven features for React Router will go through all stages. Some features, if trivial or obvious enough, may skip stages and be implemented directly as a stable feature.
81
+
82
+
This table gives a high-level overview of the stages, but please see the individual stage sections below for more detailed information on the stages and the process for moving an FC through them. Once a feature reaches Stage 2, it will be added to the [Roadmap](https://github.com/orgs/remix-run/projects/5) where it can be tracked as it moves through the stages.
@@ -87,8 +90,6 @@ Once a feature reaches Stage 2, it will be added to the [Roadmap](https://github
87
90
| 4 | Stabilization | At least 1 month in the Beta stage and PR opened to stabilize the APIs. This PR should also include documentation for the new feature. | The **Stabilization** phase exists to ensure that unstable features are available for enough time for applications to update their React Router version and opt-into beta testing. We don't want to rush features through beta testing so that we have maximal feedback prior to stabilizing a feature. |
88
91
| 5 | Stable | PR approval from at least 50% of the SC members indicating their acceptance of the PR for a stable API | A RFC is completed and enters the **Stable** stage once enough members of the SC feel comfortable not only with the code for the stable feature, but have also seen positive feedback from beta testers that the feature is working as expected. Once an **Beta** stage PR has enough SC approvals and has spent the required amount of time in the **Beta** stage, it can be merged and included in the next React Router release. |
89
92
90
-
To get a feature accepted and implemented in React Router, it will go through the following stages:
Copy file name to clipboardExpand all lines: docs/api/framework-conventions/server-modules.md
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@ title: .server modules
11
11
Server-only modules that are excluded from client bundles and only run on the server.
12
12
13
13
```ts filename=auth.server.ts
14
-
// This would expose secrets on the client
14
+
// This would expose secrets on the client if not exported from a server-only module
15
15
exportconst JWT_SECRET =process.env.JWT_SECRET;
16
16
17
17
exportfunction validateToken(token:string) {
@@ -21,12 +21,19 @@ export function validateToken(token: string) {
21
21
22
22
`.server` modules are a good way to explicitly mark entire modules as server-only. The build will fail if any code in a `.server` file or `.server` directory accidentally ends up in the client module graph.
23
23
24
+
<docs-warning>
25
+
26
+
Route modules should not be marked as `.server` or `.client` as they have special handling and need to be referenced in both server and client module graphs. Attempting to do so will cause build errors.
27
+
28
+
</docs-warning>
29
+
24
30
<docs-info>
25
31
26
32
If you need more sophisticated control over what is included in the client/server bundles, check out the [`vite-env-only` plugin](https://github.com/pcattori/vite-env-only).
Copy file name to clipboardExpand all lines: docs/explanation/code-splitting.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,7 +31,7 @@ Instead of bundling all routes into a single giant build, the modules referenced
31
31
32
32
Because these entry points are coupled to URL segments, React Router knows just from a URL which bundles are needed in the browser, and more importantly, which are not.
33
33
34
-
If the user visits `"/about"` then the bundles for `about.tsx` will be loaded but not `contact.tsx`. This ensures drastically reduces the JavaScript footprint for initial page loads and speeds up your application.
34
+
If the user visits `"/about"` then the bundles for `about.tsx` will be loaded but not `contact.tsx`. This drastically reduces the JavaScript footprint for initial page loads and speeds up your application.
Copy file name to clipboardExpand all lines: docs/how-to/file-uploads.md
+9-11Lines changed: 9 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,8 +9,6 @@ title: File Uploads
9
9
<br/>
10
10
<br/>
11
11
12
-
Handle file uploads in your React Router applications. This guide uses some packages from the [Remix The Web][remix-the-web] project to make file uploads easier.
13
-
14
12
_Thank you to David Adams for [writing an original guide](https://programmingarehard.com/2024/09/06/remix-file-uploads-updated.html/) on which this doc is based. You can refer to it for even more examples._
15
13
16
14
## Basic File Upload
@@ -38,7 +36,7 @@ export default [
38
36
`form-data-parser` is a wrapper around `request.formData()` that provides streaming support for handling file uploads.
39
37
40
38
```shellscript
41
-
npm i @mjackson/form-data-parser
39
+
npm i @remix-run/form-data-parser
42
40
```
43
41
44
42
[See the `form-data-parser` docs for more information][form-data-parser]
@@ -57,11 +55,12 @@ You must set the form's `enctype` to `multipart/form-data` for file uploads to w
@@ -93,7 +92,7 @@ export default function Component() {
93
92
`file-storage` is a key/value interface for storing [File objects][file] in JavaScript. Similar to how `localStorage` allows you to store key/value pairs of strings in the browser, file-storage allows you to store key/value pairs of files on the server.
94
93
95
94
```shellscript
96
-
npm i @mjackson/file-storage
95
+
npm i @remix-run/file-storage
97
96
```
98
97
99
98
[See the `file-storage` docs for more information][file-storage]
@@ -103,7 +102,7 @@ npm i @mjackson/file-storage
103
102
Create a file that exports a `LocalFileStorage` instance to be used by different routes.
Copy file name to clipboardExpand all lines: docs/start/data/route-object.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -194,7 +194,7 @@ A route loader is revalidated when:
194
194
195
195
- its own route params change
196
196
- any change to URL search params
197
-
- after any actions are called
197
+
- after an action is called and returns a non-error status code
198
198
199
199
By defining this function, you opt out of the default behavior completely and can manually control when loader data is revalidated for navigations and form submissions.
0 commit comments