Skip to content

Correcting and clarifying the nonce copy #6239

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 24, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/content/guides/csp.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ related:
url: https://web.dev/trusted-types
---

Webpack is capable of adding `nonce` to all scripts that it loads. To activate the feature set a `__webpack_nonce__` variable needs to be included in your entry script. A unique hash based nonce should be generated and provided for each unique page view this is why `__webpack_nonce__` is specified in the entry file and not in the configuration. Please note that `nonce` should always be a base64-encoded string.
Webpack is capable of adding a `nonce` to all scripts that it loads. To activate this feature, set a `__webpack_nonce__` variable and include it in your entry script. A unique hash-based `nonce` will then be generated and provided for each unique page view (this is why `__webpack_nonce__` is specified in the entry file and not in the configuration). Please note that the `__webpack_nonce__` should always be a base64-encoded string.

## Examples

Expand Down