Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/rewire.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Ewald <johannes.ewald@peerigon.com>2015-02-25 03:29:45 +0300
committerJohannes Ewald <johannes.ewald@peerigon.com>2015-02-25 03:29:45 +0300
commitc61f0eeb5cf56aaee2f0133871ecded2a91c5582 (patch)
tree90d92bb6a9f244ab8df80cea15b6253f730428d5 /README.md
parent530f508561a304318895997f392650652f09624b (diff)
Add downloadRank to npm badge
Diffstat (limited to 'README.md')
-rw-r--r--README.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/README.md b/README.md
index 39d8936..8d88212 100644
--- a/README.md
+++ b/README.md
@@ -22,7 +22,7 @@ case CoffeeScript needs to be listed in your devDependencies.
If you want to use rewire also on the client-side take a look at [client-side bundlers](https://github.com/jhnns/rewire#client-side-bundlers)
-[![npm status](https://nodei.co/npm/rewire.svg?downloads=true&stars=true)](https://npmjs.org/package/rewire)
+[![npm status](https://nodei.co/npm/rewire.svg?downloads=true&stars=true&downloadRank=true)](https://npmjs.org/package/rewire)
<br />
@@ -106,7 +106,7 @@ var revert = myModule.__set__("port", 3000);
// port is now 3000
revert();
-// port is now the previous value
+// port is now the previous value
```
For your convenience you can also use the `__with__` method which reverts the given changes after it finished.
@@ -138,7 +138,7 @@ myModule.__with__({
**Difference to require()**<br>
Every call of rewire() executes the module again and returns a fresh instance.
-```javascript
+```javascript
rewire("./myModule.js") === rewire("./myModule.js"); // = false
```
@@ -170,7 +170,7 @@ API
### rewire(filename: String): rewiredModule
-Returns a rewired version of the module found at `filename`. Use `rewire()` exactly like `require()`.
+Returns a rewired version of the module found at `filename`. Use `rewire()` exactly like `require()`.
### rewiredModule.&#95;&#95;set&#95;&#95;(name: String, value: *): Function