We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b9954ce commit 1bd4a89Copy full SHA for 1bd4a89
index.js
@@ -0,0 +1,6 @@
1
+'use strict'
2
+const nodeVersion = parseInt(process.versions.node)
3
+module.exports =
4
+ // in Node v14.x, hrtime() is 2x slower
5
+ nodeVersion === 14 ? Date.now :
6
+ require('./now')
package.json
@@ -1,9 +1,8 @@
{
"name": "@spazmodius/now",
- "version": "1.0.1",
+ "version": "1.1.0",
"description": "Faster now() for Node.js",
"repository": "github:spazmodius/now",
- "main": "now.js",
7
"scripts": {
8
"test": "node test/test.js",
9
"bench": "node test/vs-Date-now.js"
0 commit comments