Skip to content

Commit d097ca2

Browse files
fix code highlights (#973)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
1 parent 78e2aea commit d097ca2

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/routes/solid-router/reference/response-helpers/reload.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@ title: reload
55
Reload is a response helper built on top of [revalidate](/solid-router/reference/response-helpers/revalidate).
66
It will receive a cache key, or an array of cache keys, to invalidate those queries, and cause them to fire again.
77

8-
```ts title="/actions/update-todo.ts"{4}
8+
```ts title="/actions/update-todo.ts" {7}
99
import { action, reload } from "@solidjs/router";
1010
import { putTodo, getTodo } from "../db";
1111

1212
const updateTodo = action(async (todo: Todo) => {
1313
await putTodo(todo.id, todo);
1414

15-
return reload({ revalidate: getTodo.keyFor(id) });
15+
return reload({ revalidate: getTodo.keyFor(id) });
1616
});
1717
```
1818

src/routes/solid-router/reference/response-helpers/revalidate.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ If you intend to re-fire the queries immediately, check the [reload](/solid-rout
1010

1111
The code below will revalidate the `getTodo` query with the cache key.
1212

13-
```ts title="/actions/update-todo.ts"{4}
13+
```ts title="/actions/update-todo.ts" {6}
1414
import { action, revalidate } from "@solidjs/router";
1515

1616
const updateTodo = action(async (todo: Todo) => {
@@ -26,7 +26,7 @@ To better understand how queries work, check the [query](/solid-router/reference
2626

2727
The `revalidate` function also accepts a second parameter to force the revalidation of the cache data.
2828

29-
```ts title="/actions/update-todo.ts"{4}
29+
```ts title="/actions/update-todo.ts" {6}
3030
import { action, revalidate } from "@solidjs/router";
3131

3232
const updateTodo = action(async (todo: Todo) => {

0 commit comments

Comments
 (0)