A Webpack loader that performs string or regex replacements on file contents during the build process. Version 3.3.0 is the latest stable release, with occasional minor/patch updates. It supports plain string replacement, RegExp replacement (via string with flags or RegExp object), multiple replacements in a single rule, callback-based dynamic replacement, and strict mode. Key differentiators: flexible configuration similar to String.prototype.replace, array of replacements, strict mode to ensure replacements occurred. Compared to alternatives like `replace-in-file-webpack-plugin` or `webpack-replace-loader`, this loader integrates directly into the loader chain and works per-file based on test patterns. Requires Webpack 5+ and Node.js 4+.
Verified import paths — ran on the pinned version, not inferred.
This is a Webpack loader, not a regular library. It is referenced by the 'loader' field in Webpack config rules. No import statement needed; just configure in webpack.config.js.
Demonstrates basic replacement of 'jQuery' with 'window.$' in all .js files.
Breaking-change detection hasn't run for this library yet.
CVE tracking and dependency tree are planned for a later release.