replaceall
Replace all instances in a JavaScript string
Last updated 4 years ago by leecrossley .
Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install replaceall 
SYNC missed versions from official npm registry.

replaceall Build Status npm version devDependency Status

Replace all instances in a JavaScript string.

Install with npm

npm install replaceall

To then include replaceall in your node app:

var replaceall = require("replaceall");

Using replaceall

var result = replaceall("instances of this", "with this string", "in this string");

Example

var original = "hello world goodbye world";

replaceall("world", "everyone", original);
// "hello everyone goodbye everyone"

replaceall("l", "z", original);
// "hezzo worzd goodbye worzd"

License

MIT License

Current Tags

  • 0.1.6                                ...           latest (4 years ago)

9 Versions

  • 0.1.6                                ...           4 years ago
  • 0.1.5                                ...           5 years ago
  • 0.1.4                                ...           5 years ago
  • 0.1.3                                ...           5 years ago
  • 0.1.2                                ...           5 years ago
  • 0.1.1                                ...           5 years ago
  • 0.1.0                                ...           6 years ago
  • 0.0.2                                ...           6 years ago
  • 0.0.1                                ...           6 years ago
Maintainers (1)
Downloads
Today 1
This Week 531
This Month 1,133
Last Day 158
Last Week 445
Last Month 2,727
Dependencies (0)
None
Dev Dependencies (5)

Copyright 2014 - 2016 © taobao.org |