<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <title>package-trends releases</title>
  <subtitle>npm download trends as a sparkline, a calendar heatmap, a line of text, or a KPI block. Compare packages, repair npm's missing days. Zero dependencies, works without a proxy.</subtitle>
  <link rel="self" href="https://tbudin.github.io/package-trends/feed.xml"/>
  <link href="https://tbudin.github.io/package-trends/changelog/"/>
  <id>https://tbudin.github.io/package-trends/changelog/</id>
  <updated>2026-10-29T17:29:16+08:00</updated>
  <author><name>Thomas Budin</name></author>
  <entry>
    <title>package-trends 0.2.1</title>
    <link href="https://tbudin.github.io/package-trends/changelog/#v0-2-1"/>
    <id>https://tbudin.github.io/package-trends/changelog/#v0-2-1</id>
    <updated>2026-10-29T17:29:16+08:00</updated>
    <content type="html"><![CDATA[<h3>Patch Changes</h3>
<ul class="release-changes"><li><p>The README stated three bundle sizes and all three had drifted, the React one by 2 kB in the flattering direction, because nothing measured them. They are corrected — 8.3 kB for the core, 12.5 kB with the React components, 14.8 kB with comparison, 17.1 kB with the heatmap as well — and <code>pnpm check</code> now fails on a figure the package no longer has, or on an entry point the README never mentions.</p><p>Accessibility covers the heatmap too: it always carries <code>role=&quot;img&quot;</code> and a generated <code>aria-label</code>, where an unlabelled sparkline marks itself <code>aria-hidden</code>, and <code>cellTitles</code> is explained along with why it is on in the component and off in <code>heatmapSvg</code>.</p><p>No runtime code changed, so the published bundles are identical to 0.2.0.</p></li></ul>]]></content>
  </entry>
  <entry>
    <title>package-trends 0.2.0</title>
    <link href="https://tbudin.github.io/package-trends/changelog/#v0-2-0"/>
    <id>https://tbudin.github.io/package-trends/changelog/#v0-2-0</id>
    <updated>2026-10-29T15:54:32+08:00</updated>
    <content type="html"><![CDATA[<h3>Minor Changes</h3>
<ul class="release-changes"><li><p>A calendar heatmap: one square per day, one column per week, from a new <code>/heatmap</code> entry. <code>&lt;PackageHeatmap&gt;</code> in React, <code>heatmapSvg()</code> for a string, and <code>heatmapGeometry()</code> for the squares as data — all three drawing from one computation, so a server render and the client agree square for square.</p><p>It shows the two things a sparkline averages away: where in the year a quiet stretch fell, and the weekday rhythm. Across react's last year Wednesday averages 20.6M against Saturday's 11.3M.</p><p>The ramp is opacity over <code>currentColor</code>, so lightness alone carries the value: it inherits the surrounding text colour, inverts on a dark ground with no second palette, and survives monochrome. <code>emptyColor</code> gives the quietest level a colour of its own for GitHub's two-tone look. <code>scale</code> defaults to <code>&quot;linear&quot;</code> spanning zero, because <code>&quot;quantile&quot;</code> fills the ramp evenly and so draws a year that doubled and a year that never moved identically. Days npm reported nothing for are hatched rather than shaded, since a solid square would state a number nobody measured.</p></li></ul>
<h3>Patch Changes</h3>
<ul class="release-changes"><li><p><code>computeTrend</code>, <code>compare</code> and <code>analyse</code> all answered nonsense for a range with no points. The first two threw a raw <code>TypeError</code>, and a throw inside a React render takes the whole tree with it — on a server that is the page, not the chart. <code>analyse</code> was quieter and worse: NaN for <code>mean</code> and <code>median</code>, and <code>undefined</code> for <code>peak</code> and <code>trough</code> behind a type promising a <code>DownloadPoint</code>.</p><p>All three now throw <code>PackageTrendsError</code> with the package named, and the hooks route a failed derivation into the <code>error</code> state they already had, so <code>renderError</code> handles it like any other failure. Renderers are unchanged: <code>sparkline</code> and <code>heatmapGeometry</code> can honestly draw nothing, and <code>&lt;PackageHeatmap&gt;</code> now shows its fallback rather than a zero-sized <code>&lt;svg&gt;</code>.</p><p><code>svgProps</code> is typed to accept the <code>data-*</code> attributes its own documentation promised; the type had been rejecting them.</p></li></ul>]]></content>
  </entry>
  <entry>
    <title>package-trends 0.1.0</title>
    <link href="https://tbudin.github.io/package-trends/changelog/#v0-1-0"/>
    <id>https://tbudin.github.io/package-trends/changelog/#v0-1-0</id>
    <updated>2026-10-28T22:19:48+08:00</updated>
    <content type="html"><![CDATA[<h3>Minor Changes</h3>
<ul class="release-changes"><li><p>Column charts, a fixed <code>domain</code> so two charts can be compared, point marks, settable up/down colours, and <code>analyse()</code> for writing about a series programmatically.</p><p>Adds a <code>styles</code> object for weight, display and spacing; <code>numberFormat</code> and <code>percentFormat</code> taking <code>Intl.NumberFormat</code> options; <code>interactive</code> for pointer and keyboard inspection; <code>aggregate: &quot;month&quot;</code>; <code>between()</code> for an explicit date range; a <code>band</code> chart of each period's low, mean and high; CSS lengths for <code>width</code> and <code>height</code> so a chart can scale with its text; <code>curve</code> for smooth, stepped or straight lines; <code>strokeDasharray</code>, <code>pathProps</code> and <code>fillPattern</code> for patterned charts; and <code>svgProps</code> for anything else the <code>&lt;svg&gt;</code> should carry.</p><p>Also repairs the zeros npm reports for days it has no data for. Taken literally they understate the mean by a quarter and invert the weekday profile; they are now interpolated, and listed in <code>gapDays</code>.</p></li><li><p>Compare several packages at once, from a new <code>/compare</code> entry: <code>&lt;PackageComparison&gt;</code> as an overlaid chart or a row each, <code>compare()</code> and <code>indexSeries()</code> in the core, and <code>fetchMany</code> so a page asks for each distinct name only once.</p><p><code>scale=&quot;indexed&quot;</code> restates each series against its own start, which is the only honest way to put packages of very different sizes on one chart.</p></li><li><p>First release. npm download trends as a sparkline, a line of text or a KPI block, with a framework-agnostic core and a React entry. Pass <code>data</code> from a server-side <code>fetchDownloads</code> to render without a request per visitor.</p></li></ul>]]></content>
  </entry>
</feed>
