Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
Luxon Compare to Today
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:142.0) Gecko/20100101 Firefox/142.0
Browser:
Firefox 142
Operating system:
Mac OS X 10.15
Device Platform:
Desktop
Date tested:
9 months ago
Test name
Executions per second
new Date()
17240976.0 Ops/sec
Luxon Today
641807.8 Ops/sec
isHidden
78972.7 Ops/sec
HTML Preparation code:
<script src="https://cdnjs.cloudflare.com/ajax/libs/luxon/3.7.1/luxon.min.js" integrity="sha512-6ag6FsASeZJY0+rPreN3NyOvKumkTBIjyn3mOkK4tpKxpip1JEMqEvq8F6EgPHqc8PVBf/cSzsyWeak7XjdH9w==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
Script Preparation code:
function coerceToDate(value) { if (!value) return undefined; if (value instanceof Date) return Number.isNaN(value.getTime()) ? undefined : value; const dateTime = [ luxon.DateTime.fromISO(value), luxon.DateTime.fromFormat(value, 'M-d-yyyy'), luxon.DateTime.fromFormat(value, 'M/d/yyyy') ].find(i => i.isValid); return dateTime?.toJSDate() ?? undefined; }
Tests:
new Date()
new Date()
Luxon Today
const today = luxon.DateTime.now().startOf('day');
isHidden
const today = luxon.DateTime.now().startOf('day'); const expirationDate = luxon.DateTime.fromJSDate(coerceToDate('2025-02-11')).startOf('day'); return (expirationDate < today);