Skip to content

Conversation

@jescalan
Copy link
Contributor

@jescalan jescalan commented Nov 6, 2024

Description

If using a strict-dynamic CSP with Clerk, you still currently need to add unsafe-inline to the style-src property since we do not thread the nonce into the emotion cache. This change will make it such that you can run the nonce into style-src instead of unsafe-inline and it will work, which means there are no unsafe properties required to be passed for strict dynamic policies when using Clerk in production.

Checklist

  • npm test runs as expected.
  • npm run build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other:

@changeset-bot
Copy link

changeset-bot bot commented Nov 6, 2024

🦋 Changeset detected

Latest commit: f10d02d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@clerk/clerk-js Minor
@clerk/chrome-extension Patch
@clerk/clerk-expo Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Member

@jacekradko jacekradko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jescalan The changes look good. Thanks!

@vercel
Copy link

vercel bot commented Nov 22, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
clerk-js-sandbox ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 22, 2024 2:13pm

@jescalan jescalan merged commit 7c27b0c into main Nov 22, 2024
27 checks passed
@jescalan jescalan deleted the je.nonce-style branch November 22, 2024 16:34
wobsoriano pushed a commit that referenced this pull request Feb 8, 2025
Co-authored-by: Jacek <jacek@clerk.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants