• Version 1.1.4
  • Published
  • 15.1 kB
  • 5 dependencies
  • MIT license


npm i gulp-replace
yarn add gulp-replace
pnpm add gulp-replace


A string replace plugin for gulp




function replace

replace: (
search: string | RegExp,
replacement: string | Replacer,
options?: Options
) => NodeJS.ReadWriteStream;
  • Searches and replaces a portion of text using a string or a RegExp.

    Parameter search

    The string or RegExp to search for.

    Parameter replacement

    The replacement string or a function for generating a replacement.

    If replacement is a function, it will be called once for each match and will be passed the string that is to be replaced. The value of this.file will be equal to the vinyl instance for the file being processed.

    Read more at [String.prototype.replace() at MDN web docs](").

    Parameter options

    options.skipBinary will be equal to true by default.

    Skip binary files. This option is true by default. If you want to replace content in binary files, you must explicitly set it to false.

Package Files (1)

Dependencies (5)

Dev Dependencies (7)

Peer Dependencies (0)

No peer dependencies.


To add a badge like this badgeto your package's README, use the codes available below.

You may also use to create a custom badge linking to

  • Markdown
  • HTML
    <a href=""><img src="" alt=""></a>