Skip to content

Commit 2e65318

Browse files
committed
chore: format
1 parent 9339801 commit 2e65318

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

CHANGELOG.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ In 2.9.2 we've enhanced the type-safety when opting into the `future.unstable_si
189189
With this release we're introducing new functions to assist the type-inference when using single fetch - `defineLoader`/`defineAction` and their client-side counterparts `defineClientLoader` and nd `defineClientAction`. These are identity functions; they don't modify your loader or action at runtime. Rather, they exist solely for type-safety by providing types for args and by ensuring valid return types.
190190

191191
```ts
192-
export let loader = defineLoader(({ request }) => {
192+
export const loader = defineLoader(({ request }) => {
193193
// ^? Request
194194
return { a: 1, b: () => 2 };
195195
// ^ type error: `b` is not serializable
@@ -200,7 +200,7 @@ Note that `defineLoader` and `defineAction` are not technically necessary for de
200200

201201
```ts
202202
// this totally works! and typechecking is happy too!
203-
export let loader = () => {
203+
export const loader = () => {
204204
return { a: 1 };
205205
};
206206
```

packages/remix-deno/CHANGELOG.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@
44

55
### Patch Changes
66

7-
- Typesafety for single-fetch: `defineLoader`, `defineClientLoader`, `defineAction`, `defineClientAction` ([#9372](https://github.com/remix-run/remix/pull/9372), [#9404](https://github.com/remix-run/remix/pull/9404))
7+
- Typesafety for single-fetch: `defineLoader`, `defineClientLoader`,
8+
`defineAction`, `defineClientAction`
9+
([#9372](https://github.com/remix-run/remix/pull/9372),
10+
[#9404](https://github.com/remix-run/remix/pull/9404))
811
- Updated dependencies:
912
- `@remix-run/[email protected]`
1013

0 commit comments

Comments
 (0)