We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 657385f commit dc9799dCopy full SHA for dc9799d
index.js
@@ -1,5 +1,6 @@
1
-import {readFileSync} from 'node:fs';
2
-import {readFile} from 'node:fs/promises';
+import {readFileSync, promises as fs} from 'node:fs';
+
3
+const {readFile} = fs;
4
5
const parse = (buffer, {beforeParse, reviver} = {}) => {
6
// Unlike `buffer.toString()` and `fs.readFile(path, 'utf8')`, `TextDecoder`` will remove BOM.
0 commit comments