Skip to content

Conversation

@L-Mario564
Copy link
Collaborator

@L-Mario564 L-Mario564 commented Oct 27, 2025

This PR aims to migrate from using tsup and Rollup to using Rolldown.

  • All packages are now built using Rolldown and for any additional build steps they have in common, those functions are present in the top-level build folder.
  • Replace recast with oxc-parser and magic-string while also parallelizing the task to fix CJS imports. This leads to some performance gains, around 1-2 seconds faster for smaller packages or up to 2x-3x faster for larger packages like drizzle-orm.
  • Use Bun instead of zx, cpy and tsx.
  • The dist output for the validator packages and drizzle-seed are practically identical due to the Rolldown API being highly compatible with Rollup.
  • drizzle-orm's dist output is different from the one produced by tsup. It should work for both CJS and ESM. If any entrypoints are missing they can be added in the rolldown.config.ts file.
  • drizzle-kit's dist output is also different. The dev build script was already erroring when I began working on this migration so I tried my best to migrate that. The regular build, CLI build and external build should work as expected.
  • Fixed some minor issues related to stripping internal exports.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants