Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
split vs slice date ranges for cally
Javascript split vs slice performance
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36 Edg/134.0.0.0
Browser:
Chrome 134
Operating system:
Windows
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
split
11396031.0 Ops/sec
slice
59328740.0 Ops/sec
substring
56295652.0 Ops/sec
Script Preparation code:
var date = "31/03/2025 - 06/03/2025";
Tests:
split
const [start, end] = date.split("/");
slice
const start = date.slice(0, 10); const end = date.slice(13, 23);
substring
const start = date.substring(0, 10); const end = date.substring(13, 23);