Skip to content

feat: publish @pgflow/edge-worker to npm with Node/Bun process runtime support#628

Open
jumski wants to merge 1 commit into
portable-worker-process-adapterfrom
portable-worker-npm-build
Open

feat: publish @pgflow/edge-worker to npm with Node/Bun process runtime support#628
jumski wants to merge 1 commit into
portable-worker-process-adapterfrom
portable-worker-npm-build

Conversation

@jumski
Copy link
Copy Markdown
Contributor

@jumski jumski commented Jun 7, 2026

@pgflow/edge-worker is now published to npm alongside the other pgflow packages. Previously it was excluded from npm publishing and only released to JSR.

To support npm distribution, the following changes were made:

  • The TypeScript build target for edge-worker is now active, compiling sources to dist/ via @nx/js:tsc
  • Import paths updated from .ts to .js extensions for compatibility with compiled output
  • Replaced the @std/crypto/timing-safe-equal Deno dependency with an inline timingSafeEqualBytes implementation, removing the Deno-specific dependency and enabling Node/Bun compatibility
  • globalThis.crypto access updated to avoid TypeScript strict-mode errors in non-browser environments
  • TypeScript config updated to include es2022, dom, and dom.iterable libs
  • A smoke test script (scripts/smoke-edge-worker-dist.mjs) was added to verify the built dist/ exports are valid before publishing
  • The validate:publish:npm and publish:npm scripts now include edge-worker and run the smoke test as part of the publish flow

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Jun 7, 2026

🦋 Changeset detected

Latest commit: ff59b77

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

This PR includes changesets to release 5 packages
Name Type
@pgflow/core Minor
@pgflow/dsl Minor
@pgflow/client Minor
@pgflow/edge-worker Minor
pgflow Minor

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
Copy Markdown
Contributor Author

jumski commented Jun 7, 2026

@nx-cloud
Copy link
Copy Markdown

nx-cloud Bot commented Jun 7, 2026

View your CI Pipeline Execution ↗ for commit ff59b77

Command Status Duration Result
nx affected -t lint typecheck test --parallel -... ❌ Failed 54s View ↗
nx run edge-worker:test:integration ❌ Failed 1m View ↗
nx run client:e2e ✅ Succeeded 3m 2s View ↗
nx run core:pgtap ✅ Succeeded 1m 47s View ↗
nx run edge-worker:e2e ✅ Succeeded 50s View ↗
nx run cli:e2e ✅ Succeeded 3s View ↗

💡 Dealing with memory or CPU issues? See memory and CPU details with the resource usage add-on ↗.


☁️ Nx Cloud last updated this comment at 2026-06-07 23:31:13 UTC

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.

1 participant