Skip to content

feat!: migrate @doist/react-interpolate to tsdown#56

Merged
gnapse merged 2 commits into
nextfrom
ernesto/react-interpolate-tsdown
May 21, 2026
Merged

feat!: migrate @doist/react-interpolate to tsdown#56
gnapse merged 2 commits into
nextfrom
ernesto/react-interpolate-tsdown

Conversation

@gnapse
Copy link
Copy Markdown

@gnapse gnapse commented May 21, 2026

Summary

  • Replace the Rollup/Babel/Uglify pipeline with tsdown, keep dual ESM/CJS output, and publish an explicit exports contract for the package.
  • Remove legacy build artifacts and Babel runtime dependencies, stop publishing src/, and keep package-compat coverage focused on the package entrypoint shape.
  • Modernize the compatibility contract as part of this breaking release: move the package to Node ^22.18.0 || >=24.0.0, switch CI/release workflows to a single .node-version source of truth, and stop preserving the previous IE11-era transpilation baseline.

Breaking Changes

  • Node support is now ^22.18.0 || >=24.0.0.
  • Published browser syntax is now aligned with modern consumer toolchains rather than the previous Babel-downleveled legacy baseline.

Validation

  • npm run typecheck
  • npm test -- --runInBand
  • npm run lint
  • npm run build
  • npm run test:package
  • npx publint
  • npm pack
  • Isolated installed-package smoke tests for require('@doist/react-interpolate') and await import('@doist/react-interpolate')

Reference

@gnapse gnapse changed the title [codex] Migrate build to tsdown build: migrate package build to tsdown May 21, 2026
@gnapse gnapse force-pushed the ernesto/react-interpolate-tsdown branch from 2842d3d to 30d2256 Compare May 21, 2026 19:06
@gnapse gnapse self-assigned this May 21, 2026
@gnapse gnapse marked this pull request as ready for review May 21, 2026 19:07
Copy link
Copy Markdown
Member

@doistbot doistbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This pull request successfully migrates the build pipeline from the legacy Rollup and Babel setup to tsdown while maintaining dual ESM/CJS outputs and updating the associated configurations. This transition cleans up legacy dependencies and modernizes the build tooling, which is a great step forward for the repository's long-term maintainability. However, there are a few areas to refine, including ensuring the test matrix aligns with the declared Node engines, restoring the browser compatibility target to prevent breaking changes with ES2020 syntax, syncing the CI Node version with .nvmrc, and strengthening the package compatibility tests to validate the actual installed tarball.

Share FeedbackReview Logs

Comment thread .github/workflows/check-pull-request-health.yml Outdated
Comment thread tsdown.config.ts
Comment thread .github/workflows/check-pull-request-health.yml Outdated
Comment thread __test__/package-smoke.cjs
@gnapse gnapse force-pushed the ernesto/react-interpolate-tsdown branch from f80f8ea to 77c1045 Compare May 21, 2026 20:00
@gnapse gnapse changed the title build: migrate package build to tsdown feat!: modernize package contract and node support May 21, 2026
@gnapse gnapse requested a review from doistbot May 21, 2026 20:02
@gnapse gnapse changed the title feat!: modernize package contract and node support feat!: migrate @doist/react-interpolate to tsdown May 21, 2026
@gnapse gnapse requested a review from rfgamaral May 21, 2026 20:05
@gnapse gnapse merged commit ea74478 into next May 21, 2026
2 checks passed
@gnapse gnapse deleted the ernesto/react-interpolate-tsdown branch May 21, 2026 20:05
Copy link
Copy Markdown
Member

@doistbot doistbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR modernizes the package build pipeline with tsdown and updates the compatibility contract for newer Node environments. These updates significantly streamline the build process and align the published artifacts with modern toolchains. There are just a few remaining adjustments needed to remove an outdated self-referencing smoke test and ensure CI fully covers the newly added Node 24 compatibility range.

Share FeedbackReview Logs

async function main() {
const cjsPackage = require('..')
const esmPackage = await import('../dist/react-interpolate.mjs')
const cjsPackage = require('@doist/react-interpolate')
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P2] This file still relies on Node self-referencing instead of testing a packed tarball. Since you noted in the previous review that this smoke test would be removed, it appears it was mistakenly modified instead. If it's no longer needed, remember to delete this file and remove its execution from the test:package script.

uses: actions/checkout@v4

- name: Setup Node.js ${{ matrix.node-version }}
- name: Setup Node.js from .node-version
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P2] This workflow now only exercises the single version pinned in .node-version, but package.json newly declares support for >=24.0.0 as well. That means the Node 24 part of the published engines contract is untested in CI. Add a second 24.x job/matrix entry here, or narrow engines.node to the version(s) you actually verify.

Copy link
Copy Markdown
Member

@rfgamaral rfgamaral left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

3 participants