MCPcopy Create free account
hub / github.com/GooseMod/OpenAsar / tree

Function tree

scripts/strip.js:49–57  ·  view source on GitHub ↗
(dirPath)

Source from the content-addressed store, hash-verified

47const stripJson = (path) => writeFileSync(path, JSON.stringify(minJson(JSON.parse(readFileSync(path, 'utf8')))));
48
49const tree = (dirPath) => readdirSync(dirPath).forEach((x) => {
50 const path = join(dirPath, x);
51 console.log(path);
52
53 if (x.endsWith('.js')) return stripJs(path);
54 if (x.endsWith('.json')) return stripJson(path);
55 if (x.endsWith('.html')) return stripHtml(path);
56 if (!x.includes('.')) return tree(path);
57});
58
59tree(join(__dirname, '..', 'src'));

Callers 1

strip.jsFile · 0.85

Calls 3

stripJsFunction · 0.85
stripJsonFunction · 0.85
stripHtmlFunction · 0.85

Tested by

no test coverage detected