Skip to content

Commit fdec7e9

Browse files
Merge pull request #2490 from Tony133/docs/update-csrf
docs(security): update package csrf for fastify
2 parents a5b8181 + 57e7e2e commit fdec7e9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

content/security/csrf.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,16 @@ app.use(csurf());
2626
Start by installing the required package:
2727

2828
```bash
29-
$ npm i --save fastify-csrf
29+
$ npm i --save @fastify/csrf-protection
3030
```
3131

32-
Once the installation is complete, register the `fastify-csrf` plugin, as follows:
32+
Once the installation is complete, register the `@fastify/csrf-protection` plugin, as follows:
3333

3434
```typescript
35-
import fastifyCsrf from 'fastify-csrf';
35+
import fastifyCsrf from '@fastify/csrf-protection';
3636
// ...
3737
// somewhere in your initialization file after registering some storage plugin
3838
await app.register(fastifyCsrf);
3939
```
4040

41-
> warning **Warning** As explained in the `fastify-csrf` docs [here](https://github.com/fastify/fastify-csrf#usage), this plugin requires a storage plugin to be initialized first. Please, see that documentation for further instructions.
41+
> warning **Warning** As explained in the `@fastify/csrf-protection` docs [here](https://github.com/fastify/csrf-protection#usage), this plugin requires a storage plugin to be initialized first. Please, see that documentation for further instructions.

0 commit comments

Comments
 (0)