tinylibs / tinybench

🔎 A simple, tiny and lightweight benchmarking library!
MIT License
1.87k stars 37 forks source link

fix the sort function #25

Closed Aslemammad closed 2 years ago

Aslemammad commented 2 years ago

the sort function in https://github.com/tinylibs/tinybench/blob/main/src/task.ts#L76 is not correct, because it only works for strings and as you may know samples are numbers! So fix it to sort numbers. it should be something like sort((a,b) => a - b) I guess.