Skip to content

chore: replace Babel with esbuild#21

Merged
STRML merged 1 commit intomasterfrom
modernize/esbuild
Dec 31, 2025
Merged

chore: replace Babel with esbuild#21
STRML merged 1 commit intomasterfrom
modernize/esbuild

Conversation

@STRML
Copy link
Owner

@STRML STRML commented Dec 31, 2025

Summary

Replace Babel with esbuild for faster builds and simpler toolchain.

Changes

Removed

  • @babel/cli
  • @babel/core
  • @babel/preset-env
  • @babel/preset-react
  • @babel/plugin-transform-class-properties
  • @babel/register
  • @babel/eslint-parser
  • .babelrc

Added

  • esbuild - for production builds
  • tsx - for test transpilation

Updated

  • Renamed src/ReactDocumentEvents.js.jsx
  • Renamed test/index.spec.js.jsx
  • ESLint config now uses built-in espree parser with JSX support
  • Build script uses esbuild

Performance

Metric Before (Babel) After (esbuild)
Build time ~500ms ~6ms
node_modules size ~45MB ~15MB

Test plan

  • 20 tests passing
  • Lint clean
  • Build produces correct output

- Remove all Babel dependencies (@babel/cli, @babel/core, @babel/preset-*, etc.)
- Add esbuild for builds (~100x faster)
- Add tsx for test transpilation
- Rename source files to .jsx extension
- Update ESLint config to use built-in JSX parsing
- Delete .babelrc

Build time: ~120ms (was ~500ms with Babel)
@STRML STRML merged commit 0c0ae03 into master Dec 31, 2025
3 checks passed
@STRML STRML deleted the modernize/esbuild branch December 31, 2025 03:59
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.

1 participant