Weft's official packages: weft/markdown, weft/stripe, weft/email. A snapshot of packages/ in the Weft repository; MIT OR Apache-2.0.
https://pkg.weft-lang.dev/packages/weft/markdown
- JavaScript 86.8%
- Python 13.2%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
A snapshot of packages/ in the Weft repository; the official packages are published from these commits. Markup-Kit-Commit: dd1e6eb5270e62e0c8b6c202b3d01f0da6e00ddc |
||
| integration | ||
| markdown | ||
| scripts | ||
| stripe | ||
| LICENSE-APACHE | ||
| LICENSE-MIT | ||
| README.md | ||
Official packages
Packages published under the weft owner, written in Weft over HTTP APIs and std. There is no npm bridge
(docs/packages.md, Rulings): anything an app needs from the JS ecosystem is written here instead.
| package | what | capabilities |
|---|---|---|
weft/markdown |
CommonMark and GFM: a syntax tree, HTML and a sanitiser | none |
weft/stripe |
Stripe's API: customers, Checkout, payments, subscriptions, prices, products, webhooks | http.fetch@api.stripe.com |
weft/email |
Resend and Postmark, MIME with attachments, templates rendered to HTML and text | http.fetch@api.resend.com, http.fetch@api.postmarkapp.com, http.media (its Img shows the image a template names) |
Each folder is a Weft project with its own weft.toml. Its tests, benchmarks and scripts stay out of the published archive
(include in the manifest).
Trying them against a local registry
scripts/verify-local.mjs runs the whole path on this machine: it starts apps/registry, makes a publish token and a
signing key for the owner weft, publishes each package signed, and then in a fresh app runs weft add, check, run,
build --target js and install --frozen.
cargo build --release -p weft-cli # in core/
node packages/scripts/verify-local.mjs # every package, or name some: markdown stripe email
Publishing for real
None of this has happened yet. In order:
- Deploy the registry at pkg.weft-lang.dev (
apps/registry/README.md, What a deploy needs). - Make the owner's token:
POST /v1/tokenswith{ "owners": ["weft"] }and the operator'sREGISTRY_ADMIN_TOKEN.weftis a reserved owner, so only the operator can grant it. - Make the signing key offline:
weft publish --new-key, keep the secret out of the repository, and register the public key withPUT /v1/owners/weft/key. From then on the registry takes only versions signed by it. - Set each manifest's
repositoryto the public source. It is a placeholder today (https://git.weft-lang.dev/weft/packages), and a signed statement records it for good. - Publish from a clean checkout, with the commit recorded:
WEFT_TOKEN=… WEFT_SIGNING_KEY=… WEFT_COMMIT=$(git rev-parse HEAD) weft publish --sign --dir packages/<name>. - Look at the generated pages (
/packages/weft/<name>) before announcing a version: published versions can be yanked but never changed.
Before each package's first real release:
| package | still to do |
|---|---|
weft/markdown |
nothing beyond the steps above |
weft/stripe |
run its calls against a Stripe test-mode key: so far they have met only stripe-mock and a scripted server |
weft/email |
send a message through Resend and Postmark with test keys: so far they have met only a scripted server |