Skip to content

loadConfigFile

loadConfigFile<T>(opts): Promise<Loaded<T> | null>

Defined in: cli/datapad/src/load-config-file/load-config-file.ts:36

Load the first <name>.config.<ext> found starting at cwd — just cwd itself by default, or walking up through ancestor directories when walkUp is set (see the module doc comment for the stop conditions). Returns null when none is present anywhere searched; throws ConfigFileError when a file exists but cannot be loaded.

T

LoadConfigFileOptions

Promise<Loaded<T> | null>