main
Last change
on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago |
Update repo after prototype presentation
|
-
Property mode
set to
100644
|
File size:
1019 bytes
|
Rev | Line | |
---|
[d565449] | 1 | # fastest-stable-stringify
|
---|
| 2 |
|
---|
| 3 | Deterministic `JSON.stringify()` - fastest stable JSON stringifier. This project combines [fast-json-stable-stringify](https://github.com/epoberezkin/fast-json-stable-stringify) and [fast-stable-stringify](https://github.com/nickyout/fast-stable-stringify) to create the fastest stable JSON stringifier.
|
---|
| 4 |
|
---|
| 5 |
|
---|
| 6 | ## Installation
|
---|
| 7 |
|
---|
| 8 | With [npm](https://npmjs.org) do:
|
---|
| 9 |
|
---|
| 10 | ```
|
---|
| 11 | npm install fastest-stable-stringify
|
---|
| 12 | ```
|
---|
| 13 |
|
---|
| 14 | ## Usage
|
---|
| 15 |
|
---|
| 16 | ```js
|
---|
| 17 | var stringify = require('fastest-stable-stringify');
|
---|
| 18 | var str = stringify({foo: 'bar'});
|
---|
| 19 | ```
|
---|
| 20 |
|
---|
| 21 |
|
---|
| 22 | ## Benchmark
|
---|
| 23 |
|
---|
| 24 | To run benchmark
|
---|
| 25 |
|
---|
| 26 | ```
|
---|
| 27 | node benchmark
|
---|
| 28 | ```
|
---|
| 29 |
|
---|
| 30 | Results
|
---|
| 31 |
|
---|
| 32 | ```
|
---|
| 33 | fastest-stable-stringify x 11,629 ops/sec ±0.67% (92 runs sampled)
|
---|
| 34 | fast-stable-stringify x 11,352 ops/sec ±0.63% (91 runs sampled)
|
---|
| 35 | fast-json-stable-stringify x 10,085 ops/sec ±0.52% (91 runs sampled)
|
---|
| 36 | faster-stable-stringify x 8,645 ops/sec ±0.62% (87 runs sampled)
|
---|
| 37 | json-stable-stringify x 7,761 ops/sec ±0.61% (86 runs sampled)
|
---|
| 38 | The fastest is fastest-stable-stringify
|
---|
| 39 | ```
|
---|
| 40 |
|
---|
| 41 |
|
---|
| 42 | ## License
|
---|
| 43 |
|
---|
| 44 | [MIT](./LICENSE)
|
---|
Note:
See
TracBrowser
for help on using the repository browser.