Skip to contentOpen History to see the last commit
loadConfigFile.ts
8 lines250 Bytes
1import { pathToFileURL } from 'node:url' 2import { tsImport } from 'tsx/esm/api' 4export async function loadConfigFile(filePath: string) { 5 const fileURL = pathToFileURL(filePath).href 6 const loaded = await tsImport(fileURL, './')