ESBuild plugin that fixes the 'No matching export' error for react-virtualized by rewriting broken import statements. Version 1.0.6 is the latest stable release, with frequent updates (4 releases in 2024, 2 in 2025-2026). It is a lightweight, zero-config plugin that patches the specific export issue in react-virtualized's WindowScroller module. Unlike manual workarounds (e.g., patching node_modules), this plugin integrates cleanly into ESBuild and Vite esbuild optimization pipelines.
npm install esbuild-plugin-react-virtualizedVerified import paths — ran on the pinned version, not inferred.
Demonstrates basic usage of the plugin with esbuild build to fix react-virtualized import errors.
Use ESM imports or dynamic import() instead of require(). If using Jest or other CJS environments, ensure you have ESM support (e.g., --experimental-vm-modules).
If you encounter other errors from react-virtualized, consider using a different virtualized library or patching manually.
Replace react-virtualized with react-window and use its planned esbuild plugin if needed.
Use esbuild-plugin-react-virtualized as shown in the quickstart.
Use default import: import fixReactVirtualized from 'esbuild-plugin-react-virtualized'
Switch to ESM imports (e.g., use 'import' syntax) or configure your runtime to handle ESM (e.g., with --experimental-vm-modules in Node).