Commit | Line | Data |
---|---|---|
4676a95c | 1 | import { bench, group, run } from 'tatami-ng' |
26792d4d JB |
2 | |
3 | const sampleObj = { | |
4 | name: 'Sid', | |
5 | age: 29, | |
6 | engineer: true, | |
7 | expertise: ['html', 'css', 'react'], | |
8 | address: { | |
9 | city: 'New york', | |
ebf80fe4 JB |
10 | state: 'NY', |
11 | }, | |
26792d4d JB |
12 | } |
13 | ||
14 | group('JSON stringify', () => { | |
15 | bench('JSON.stringify', () => { | |
16 | JSON.stringify(sampleObj) | |
17 | }) | |
18 | }) | |
19 | ||
20 | await run({ | |
ebf80fe4 | 21 | units: true, |
26792d4d | 22 | }) |