Skip to main content
Introducing packages.sweber.dev
All posts
Release2 min read

Derivative 0.2.0: GitHub Releases, announcement toast and type filter

Derivative now reads GitHub Releases, can announce a big release with a small toast, and lets you show only the entry types your users care about. Pro adds Mastodon posts and a CSV export.

By Seya Weber

Derivative 0.2.0 is on npm. @sweberdev/derivative and @sweberdev/derivative-react gain three features, and Derivative Pro gains two.

GitHub Releases as a source

Not every project keeps a CHANGELOG.md. If you write your notes on GitHub, Derivative can now read them directly:

npx derivative build --source github --repo acme/app

Drafts are skipped, pre-releases too unless you pass --prereleases. Notes generated by GitHub are cleaned up: the "New Contributors" list and the "Full Changelog" line go, "by @user in …" becomes a link, and prefixes like feat: or fix: set the entry type. A release name that says more than the tag becomes the release title. Public repositories need no token; for private ones, set GITHUB_TOKEN.

Announcement toast

A badge is easy to miss when a release really matters. With the new announce attribute, the widget shows a small toast next to the button for the newest unread release that has a title:

<derivative-widget src="/changelog.json" announce></derivative-widget>

Each release is announced once per reader. "Show" opens the panel, "Dismiss" keeps the unread badge. Patch releases without a title never interrupt anyone. The toast is a status region, so screen readers announce it without moving focus, and a derivative-announce event tells your analytics when it appeared.

Type filter

Internal refactors and deprecations are useful in a developer changelog but noise for most app users. types limits the panel to the entry types you choose:

<derivative-widget src="/changelog.json" types="feature,fix"></derivative-widget>

In React, both are props: <WhatsNew src="/changelog.json" announce types={["feature", "fix"]} />.

Derivative Pro 0.2.0

  • Mastodon: derivative-announce post --to mastodon posts each release as a status of at most 500 characters, with the changelog link and your hashtags. The token stays in an environment variable and only needs the write:statuses scope.
  • CSV export: derivative-insights report --csv releases.csv writes readers, opens and clicks per release, plus opens per day, ready for Excel. Values that look like spreadsheet formulas are defused.

Existing licences get the update automatically. Pro starts at 12 CHF per month.

Try it

The live demo now has switches for the toast and the type filter. The docs cover the new options, and the full list of changes is in the changelog on GitHub.

Package in this post

Derivative

Self-hosted changelog and "What's new" widget, built from your Changesets, CHANGELOG.md, commits or GitHub Releases. No SaaS, no tracking.

pnpm add @sweberdev/derivative
View package

Related posts

Release

Derivative 0.1.0 released

A self-hosted changelog and "What's new" widget, built from the Changesets, CHANGELOG.md or commits you already have. No SaaS, no tracking, about 6 kB.

Derivative
Release

Cosine 0.1.0 released

Semantic search for documentation sites that runs entirely in the browser. Keyword results on the first keystroke, ranking by meaning once the model has loaded. No server, no API key.

Cosine
Release

Witness 0.1.0 released

AI notices, AI labels and machine-readable marking for Article 50 of the EU AI Act: web components, React components, image and text marking and middleware for the Vercel AI SDK.

Witness