aboutsummaryrefslogtreecommitdiffstats
path: root/vanilla/node_modules/undici/scripts/strip-comments.js
diff options
context:
space:
mode:
Diffstat (limited to 'vanilla/node_modules/undici/scripts/strip-comments.js')
-rw-r--r--vanilla/node_modules/undici/scripts/strip-comments.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/vanilla/node_modules/undici/scripts/strip-comments.js b/vanilla/node_modules/undici/scripts/strip-comments.js
new file mode 100644
index 0000000..d687a26
--- /dev/null
+++ b/vanilla/node_modules/undici/scripts/strip-comments.js
@@ -0,0 +1,10 @@
+'use strict'
+
+const { readFileSync, writeFileSync } = require('node:fs')
+const { transcode } = require('node:buffer')
+
+const buffer = transcode
+ ? transcode(readFileSync('./undici-fetch.js'), 'utf8', 'latin1')
+ : readFileSync('./undici-fetch.js')
+
+writeFileSync('./undici-fetch.js', buffer.toString('latin1'))