Repository navigation
Add Cloudflare Workers rendering and an invoice starter - #45
Merged
Merged
Conversation
…node into fix/engine-2-5-29
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cloudflare Workers can now import
renderPdffromfullbleed/cloudflare. Wrangler bundles the pinned 2.5.29 engine and fonts; the renderer uses a fresh synchronous Wasm instance and supports HTML/CSS, components, assets and optional PNG previews. The existing Node and browser APIs retain their cancellation and isolation behavior.The entry rejects unsupported timeout/abort/isolation options and bounds source and caller asset bytes. A complete invoice starter validates JSON, calculates integer-cent totals, returns private PDF attachments, and keeps public deployment URLs disabled. Its Northstar template and styling are editable.
Qualification is local workerd only. Hosted CPU/memory/startup behavior and free-plan suitability are explicitly unverified. Package version 0.8.0 keeps the engine dependency at 2.5.29.
Validation: 101 Node tests, 42 Python checks, all TypeScript surfaces, isolated tarball installation, and real workerd PDF/PNG comparisons with Node. Adapter and starter checks cover assets/fonts, styled components, long invoices, bounded input, errors and recovery; PDFs are independently read and previews visually reviewed. CI and the publish gate now require matching Windows/Linux Workers evidence alongside the existing Node/browser matrix.