MCPcopy Create free account
hub / github.com/denoland/std / parseFileSync

Function parseFileSync

dotenv/mod.ts:229–238  ·  view source on GitHub ↗
(
  filepath: string | URL,
)

Source from the content-addressed store, hash-verified

227}
228
229function parseFileSync(
230 filepath: string | URL,
231): Record<string, string> {
232 try {
233 return parse(Deno.readTextFileSync(filepath));
234 } catch (e) {
235 if (e instanceof Deno.errors.NotFound) return {};
236 throw e;
237 }
238}
239
240async function parseFile(
241 filepath: string | URL,

Callers 1

loadSyncFunction · 0.85

Calls 1

parseFunction · 0.90

Tested by

no test coverage detected