Skip to content

Commit

Permalink
Update README.md (#127)
Browse files Browse the repository at this point in the history
  • Loading branch information
federico-boncaldo authored Aug 30, 2024
1 parent c00bbf3 commit 9d4c415
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ There are few other options to use inline styles and scripts. Take a look at the

### Integration with Vite

When building assets, Laravel's Vite plugin can [generate a nonce](https://laravel.com/docs/9.x/vite#content-security-policy-csp-nonce) that you can retrieve with `Vite::useCspNonce`. You can use in your own `NonceGenerator`.
When building assets, Laravel's Vite plugin can [generate a nonce](https://laravel.com/docs/9.x/vite#content-security-policy-csp-nonce) that you can retrieve with `Vite::cspNonce`. You can use in your own `NonceGenerator`.

```php
namespace App\Support;
Expand All @@ -249,7 +249,7 @@ class LaravelViteNonceGenerator implements NonceGenerator
{
public function generate(): string
{
return Vite::useCspNonce();
return Vite::cspNonce();
}
}
```
Expand Down

0 comments on commit 9d4c415

Please sign in to comment.