Skip to content

Commit b49428c

Browse files
authored
perf: use node: prefix to bypass require.cache call for builtins (#51)
* perf: use `node:` prefix to bypass require.cache call for builtins See fastify/fastify-static#407 * chore: fix linting errors
1 parent 32b9e66 commit b49428c

File tree

4 files changed

+3
-6
lines changed

4 files changed

+3
-6
lines changed

benchmark/compiling.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
/**
32
* Globals for benchmark.js
43
*/

benchmark/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
const fs = require('fs')
2-
const path = require('path')
3-
const spawn = require('child_process').spawn
1+
const fs = require('node:fs')
2+
const path = require('node:path')
3+
const spawn = require('node:child_process').spawn
44

55
const exe = process.argv[0]
66
const cwd = process.cwd()

benchmark/kind.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
/**
32
* Globals for benchmark.js
43
*/

benchmark/matching.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
/**
32
* Globals for benchmark.js
43
*/

0 commit comments

Comments
 (0)