{"library":"string-replace-loader","type":"library","category":null,"description":"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+.","language":"javascript","status":"active","version":"3.3.0","tags":["javascript","webpack","loader","webpack-loader","replace","string-replace","regex-replace"],"install":[{"cmd":"npm install string-replace-loader","imports":["module.exports = { module: { rules: [ { test: /\\.js$/, loader: 'string-replace-loader', options: { search: 'foo', replace: 'bar' } } ] } }"]},{"cmd":"yarn add string-replace-loader","imports":[]},{"cmd":"pnpm add string-replace-loader","imports":[]}],"homepage":null,"github":"https://github.com/Va1/string-replace-loader","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/string-replace-loader","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/string-replace-loader/compatibility"},"provenance":{"verified_status":null,"verified_at":null,"last_verified":"Wed Jun 17","next_check":"Fri Jul 24","install_tag":null}}