Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
Feature Requests
FAQ
Register
Log In
Run results for:
Map - Native vs Lodash vs Ramda vs Sanctuary
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; rv:126.0) Gecko/20100101 Firefox/126.0
Browser:
Firefox 126
Operating system:
Windows
Device Platform:
Desktop
Date tested:
2 years ago
Benchmark engine:
Benchmark.js
Native
12.0M/s
Lodash
10.5M/s
Ramda
7.8M/s
Sanctuary
308/s
View exact numbers
Test name
Executions per second
✓
Native
12,043,559 Ops/sec
Lodash
10,509,062 Ops/sec
Ramda
7,805,760 Ops/sec
Sanctuary
308 Ops/sec
HTML Preparation code:
<script src="https://unpkg.com/lodash@4.17.11/lodash.min.js"></script> <script src="https://unpkg.com/ramda@0.26.1/dist/ramda.min.js"></script> <script src="https://unpkg.com/sanctuary-show@1.0.0/index.js"></script> <script src="https://unpkg.com/sanctuary-type-identifiers@2.0.1/index.js"></script> <script src="https://unpkg.com/sanctuary-type-classes@9.0.0/index.js"></script> <script src="https://unpkg.com/sanctuary-either@1.0.0/index.js"></script> <script src="https://unpkg.com/sanctuary-maybe@1.0.0/index.js"></script> <script src="https://unpkg.com/sanctuary-pair@1.0.0/index.js"></script> <script src="https://unpkg.com/sanctuary-def@0.18.1/index.js"></script> <script src="https://unpkg.com/sanctuary@0.15.0/index.js"></script>
Script Preparation code:
function double(n) { return n*2; } var data = [...Array(20)].map((v, idx) => idx);
Tests:
Native
data.map(double);
Lodash
_.map(data, double);
Ramda
R.map(double, data);
Sanctuary
sanctuary.map(double)(data);