Skip to content

Conversation

@paescuj
Copy link
Contributor

@paescuj paescuj commented Oct 17, 2025

Switching from unbuild to tsdown which is basically about to become the new de facto standard for bundling libraries in the JS ecosystem. It's fast and easy to use (no config file required).

Related changes:

  • Adding the minimum required Node.js version via engine.node in the package.json file. This is used by tsdown to determine the build target 1. This way, we can easily ensure that the correct code is generated.
  • Adjusting and simplifying the module/types/exports definitions in the package.json file. types should be set to the ESM definitions as the main type of the package "module". We don't need to explicitly define the types under exports as those are automatically resolved by TypeScript.
  • Also renaming the tsc script to the more explicit typecheck.

Footnotes

  1. https://tsdown.dev/options/target

@paescuj paescuj force-pushed the chore/switch-to-tsdown branch from 3f98671 to b9071de Compare October 17, 2025 12:45
Copy link
Member

@veritem veritem left a comment

Choose a reason for hiding this comment

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

This is really really good work, thank you!!

@veritem veritem merged commit 6ee7112 into vitest-dev:main Oct 17, 2025
4 checks passed
@paescuj paescuj deleted the chore/switch-to-tsdown branch October 17, 2025 17:14
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.

2 participants