Vite plugin that polyfills Node.js built-in globals (e.g., process, Buffer) and modules (e.g., events, stream) for browser environments. Current stable version is 0.0.2, released in 2022. Wraps @esbuild-plugins/node-globals-polyfill and @esbuild-plugins/node-modules-polyfill into a single Vite plugin. Useful for projects like web3 that depend on Node.js polyfills. Requires Vite ^3. Ships TypeScript types.
npm install vite-plugin-ngmi-polyfillVerified import paths — ran on the pinned version, not inferred.
Minimal Vite configuration using NgmiPolyfill plugin to polyfill Node.js built-ins for browser builds.
Review the included packages list and manually add additional polyfills if needed.
Upgrade Vite to version 3 or later.
Run 'npm install vite' or 'yarn add vite'.