Download react-query/integrations/react-next-15/app/_action.ts from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 249 Bytes
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-query/integrations/react-next-15/app/_action.ts
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset@1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-query/integrations/react-next-15/app/_action.ts
-
curl -L -o _action.ts https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/1e92f2d0b9e054abc23a53595fd89ad3e2b4a34e/react-query/integrations/react-next-15/app/_action.ts
249 Bytes
| 'use server' | |
| import { revalidatePath } from 'next/cache' | |
| import { countRef } from './make-query-client' | |
| export async function queryExampleAction() { | |
| await Promise.resolve() | |
| countRef.current++ | |
| revalidatePath('/', 'page') | |
| return undefined | |
| } | |