Skip to content

Commit ef934f5

Browse files
authored
docs: standardize package README structure and install guidance (#11056)
1 parent af935d0 commit ef934f5

File tree

26 files changed

+130
-147
lines changed

26 files changed

+130
-147
lines changed

packages/async-context-middleware/README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,17 @@
11
# async-context-middleware
22

3-
Middleware for storing request context in `AsyncLocalStorage` for use with [`@remix-run/fetch-router`](https://github.com/remix-run/remix/tree/main/packages/fetch-router).
3+
Request-scoped async context middleware for Remix. It stores each request context in [`AsyncLocalStorage`](https://nodejs.org/api/async_context.html#class-asynclocalstorage) so utilities can access it anywhere in the same async call stack.
44

5-
This middleware stores the request context in [`AsyncLocalStorage`](https://nodejs.org/api/async_context.html#class-asynclocalstorage) (using `node:async_hooks`), making it available to all functions in the same async execution context.
5+
## Features
6+
7+
- **Request Context Access** - Read request context from anywhere in the same async execution flow
8+
- **Simple Router Integration** - Add a single middleware at the router level
9+
- **Node Async Hooks** - Built on `node:async_hooks` `AsyncLocalStorage`
610

711
## Installation
812

913
```sh
10-
npm install @remix-run/async-context-middleware
14+
npm i remix
1115
```
1216

1317
## Usage

packages/component/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Remix Component
1+
# component
22

3-
A minimal component system that leans on JavaScript and DOM primitives.
3+
A minimal component system for the web that leans on JavaScript and DOM primitives.
44

55
## Features
66

@@ -13,7 +13,7 @@ A minimal component system that leans on JavaScript and DOM primitives.
1313
## Installation
1414

1515
```sh
16-
npm install @remix-run/component
16+
npm i remix
1717
```
1818

1919
## Getting Started

packages/compression-middleware/README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
# compression-middleware
22

3-
Middleware for compressing HTTP responses for use with [`@remix-run/fetch-router`](https://github.com/remix-run/remix/tree/main/packages/fetch-router).
3+
Response compression middleware for Remix. It negotiates `br`, `gzip`, and `deflate` from `Accept-Encoding` and applies sensible defaults for when compression is useful.
44

5-
Automatically compresses responses using `gzip`, `brotli`, or `deflate` based on the client's `Accept-Encoding` header, with intelligent defaults for media type filtering and threshold-based compression.
5+
## Features
6+
7+
- **Encoding Negotiation** - Selects the best supported encoding from `Accept-Encoding`
8+
- **Compression Guards** - Skips already-compressed responses and range-enabled responses
9+
- **Size Thresholds** - Configurable minimum response size for compression
10+
- **MIME Filtering** - Compresses only content types likely to benefit
611

712
## Installation
813

914
```sh
10-
npm install @remix-run/compression-middleware
15+
npm i remix
1116
```
1217

1318
## Usage

packages/cookie/README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
# cookie
22

3-
Simplify HTTP cookie management in JavaScript with type-safe, secure cookie handling. `@remix-run/cookie` provides a clean, intuitive API for creating, parsing, and serializing HTTP cookies with built-in support for signing, secret rotation, and comprehensive cookie attribute management.
4-
5-
HTTP cookies are essential for web applications, from session management and user preferences to authentication tokens and tracking. While the standard cookie parsing libraries provide basic functionality, they often leave complex scenarios like secure signing, secret rotation, and type-safe value handling up to you.
3+
Type-safe cookie parsing and serialization for Remix. It supports secure signing, secret rotation, and complete cookie attribute control.
64

75
## Features
86

@@ -13,7 +11,7 @@ HTTP cookies are essential for web applications, from session management and use
1311
## Installation
1412

1513
```sh
16-
npm install @remix-run/cookie
14+
npm i remix
1715
```
1816

1917
## Usage

packages/fetch-proxy/README.md

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,7 @@
11
# fetch-proxy
22

3-
`fetch-proxy` is an HTTP proxy for the [JavaScript Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API).
4-
5-
HTTP proxies are essential for many web architectures: load balancing, API gateways, development servers that forward to backend services, and middleware that needs to intercept and modify traffic. Traditional proxy implementations often require platform-specific APIs or complex server setups.
6-
7-
In the context of servers, an HTTP proxy server is a server that forwards all requests it receives to another server and returns the responses it receives. When you think about it this way, a [`fetch` function](https://developer.mozilla.org/en-US/docs/Web/API/Window/fetch) is like a mini proxy server sitting right there in your code. You send it requests, it goes and talks to some other server, and it gives you back the response it received.
8-
9-
`fetch-proxy` allows you to easily create `fetch` functions that act as proxies to "target" servers using the familiar web-standard Fetch API.
3+
HTTP proxy utilities built on the web [Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API).
4+
Use `fetch-proxy` to create `fetch` handlers that forward requests to target servers while optionally rewriting headers and cookies.
105

116
## Features
127

@@ -17,10 +12,8 @@ In the context of servers, an HTTP proxy server is a server that forwards all re
1712

1813
## Installation
1914

20-
Install from [npm](https://www.npmjs.com/):
21-
2215
```sh
23-
npm i @remix-run/fetch-proxy
16+
npm i remix
2417
```
2518

2619
## Usage

packages/fetch-router/README.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# fetch-router
22

3-
A minimal, composable router built on the [web Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API) and [`route-pattern`](../route-pattern). Ideal for building APIs, web services, and server-rendered applications across any JavaScript runtime.
3+
A minimal, composable router built on the [web Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API) and [`route-pattern`](https://github.com/remix-run/remix/tree/main/packages/route-pattern). Ideal for building APIs, web services, and server-rendered applications.
44

55
## Features
66

@@ -11,16 +11,10 @@ A minimal, composable router built on the [web Fetch API](https://developer.mozi
1111
- **Flexible Middleware**: Apply middleware globally, per-route, or to entire route hierarchies
1212
- **Easy Testing**: Use standard `fetch()` to test your routes - no special test harness required
1313

14-
## Goals
15-
16-
- **Simplicity**: A router should be simple to understand and use. The entire API surface fits in your head.
17-
- **Composability**: Small routers combine to build large applications. Middleware and nested routers make organization natural.
18-
- **Standards-Based**: Built on web standards that work across runtimes. No proprietary APIs or Node.js-specific code.
19-
2014
## Installation
2115

2216
```sh
23-
npm install @remix-run/fetch-router
17+
npm i remix
2418
```
2519

2620
## Usage

packages/file-storage/README.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
# file-storage
22

3-
`file-storage` is a key/value interface for storing [`File` objects](https://developer.mozilla.org/en-US/docs/Web/API/File) in JavaScript.
4-
5-
Handling file uploads and storage is a common requirement in web applications, but each storage backend (local disk, AWS S3, Cloudflare R2, etc.) has its own API and conventions. This fragmentation makes it difficult to write portable code that can easily switch between storage providers or support multiple backends simultaneously.
6-
7-
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 with a consistent interface regardless of the underlying storage mechanism.
3+
Key/value storage interfaces for server-side [`File` objects](https://developer.mozilla.org/en-US/docs/Web/API/File). `file-storage` gives Remix apps one consistent API across local disk and cloud object storage backends.
84

95
## Features
106

@@ -15,10 +11,8 @@ Similar to how `localStorage` allows you to store key/value pairs of strings in
1511

1612
## Installation
1713

18-
Install from [npm](https://www.npmjs.com/):
19-
2014
```sh
21-
npm install @remix-run/file-storage
15+
npm i remix
2216
```
2317

2418
## Usage

packages/form-data-middleware/README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,18 @@
11
# form-data-middleware
22

3-
Middleware for parsing [`FormData`](https://developer.mozilla.org/en-US/docs/Web/API/FormData) from incoming request bodies for use with [`@remix-run/fetch-router`](https://github.com/remix-run/remix/tree/main/packages/fetch-router).
3+
Form body parsing middleware for Remix. It parses incoming [`FormData`](https://developer.mozilla.org/en-US/docs/Web/API/FormData) and exposes `context.formData` and uploaded files on `context.files`.
4+
5+
## Features
6+
7+
- **Request Form Parsing** - Parses request body form data once per request
8+
- **File Access** - Exposes uploaded files as `context.files`
9+
- **Custom Upload Handling** - Supports pluggable upload handlers for file processing
10+
- **Error Control** - Optional suppression for malformed form data
411

512
## Installation
613

714
```sh
8-
npm install @remix-run/form-data-middleware
15+
npm i remix
916
```
1017

1118
## Usage

packages/form-data-parser/README.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,8 @@ For attackers, this creates an attack vector where malicious actors can overwhel
2626

2727
## Installation
2828

29-
Install from [npm](https://www.npmjs.com/):
30-
3129
```sh
32-
npm install @remix-run/form-data-parser
30+
npm i remix
3331
```
3432

3533
## Usage

packages/fs/README.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
# fs
22

3-
Lazy, streaming filesystem utilities for JavaScript.
4-
5-
This package provides utilities for working with files on the local filesystem using the [`LazyFile`](https://github.com/remix-run/remix/tree/main/packages/lazy-file)/ native [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) API.
3+
Lazy, streaming filesystem utilities for JavaScript. This package provides utilities for working with files on the local filesystem using the [`LazyFile`](https://github.com/remix-run/remix/tree/main/packages/lazy-file)/ native [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) API.
64

75
## Features
86

@@ -11,10 +9,8 @@ This package provides utilities for working with files on the local filesystem u
119

1210
## Installation
1311

14-
Install from [npm](https://www.npmjs.com/):
15-
1612
```sh
17-
npm install @remix-run/fs
13+
npm i remix
1814
```
1915

2016
## Usage

0 commit comments

Comments
 (0)