Compare features and performance of similar js libraries (not just stats)
- Go to tests folder
- Add a test js file similar to below code;
var Benchmark = require('benchmark');
var id = "sample001"; //Manadatory
var suite = new Benchmark.Suite(id);
// add tests
suite.add('RegExp#test', function() {
/o/.test('Hello World!');
})
.add('String#indexOf', function() {
'Hello World!'.indexOf('o') > -1;
})
module.exports = suite