Skip to content

fix: avoid 'node:crypto' cloudflare warnings#17612

Merged
Rich-Harris merged 4 commits intomainfrom
teemingc-patch-1
Feb 4, 2026
Merged

fix: avoid 'node:crypto' cloudflare warnings#17612
Rich-Harris merged 4 commits intomainfrom
teemingc-patch-1

Conversation

@teemingc
Copy link
Copy Markdown
Member

@teemingc teemingc commented Feb 4, 2026

See sveltejs/kit#15056 (comment)

Before submitting the PR, please make sure you do the following

  • It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs
  • Prefix your PR title with feat:, fix:, chore:, or docs:.
  • This message body should clearly illustrate what problems it solves.
  • Ideally, include a test that fails without this PR but passes with it.
  • If this PR changes code within packages/svelte/src, add a changeset (npx changeset).

Tests and linting

  • Run the tests with pnpm test and lint the project with pnpm lint

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Feb 4, 2026

🦋 Changeset detected

Latest commit: b30fadb

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

This PR includes changesets to release 1 package
Name Type
svelte 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

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Feb 4, 2026

Playground

pnpm add https://pkg.pr.new/svelte@17612

Comment thread .changeset/violet-pans-know.md Outdated
Copy link
Copy Markdown
Member

@paoloricciuti paoloricciuti left a comment

Choose a reason for hiding this comment

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

I think it's fine but also if it's a false positive maybe it should be solved in wrangler/esbuild?

@Rich-Harris
Copy link
Copy Markdown
Member

It's not really a false positive — this code should error in non-Node environments, it's just that it will never run in any of the non-Node environments we care about. So this LGTM I think

@Rich-Harris Rich-Harris merged commit baba15a into main Feb 4, 2026
18 checks passed
@Rich-Harris Rich-Harris deleted the teemingc-patch-1 branch February 4, 2026 16:31
@github-actions github-actions Bot mentioned this pull request Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants