Creates a new ConfigManager instance.
The application root directory URL
Reference to the Config instance that provides access to all configuration values. Available after process() method has been called.
Provides configuration values programmatically instead of loading from files. Useful for testing or when configuration needs to be generated dynamically. Calling this method disables reading config files from the file system.
The configuration values to use
Returns the ConfigManager instance for method chaining
Loads and processes configuration values. If useConfig() was called, uses those values; otherwise loads config files from the specified directory. Creates a Config instance accessible via the config property.
The directory path containing config files (relative to appRoot)
Promise that resolves when config processing is complete
ConfigManager handles loading, parsing, and managing application configuration. It can load configuration from file system directories or use explicitly provided configuration objects (useful for testing).
The manager creates a Config instance that provides type-safe access to configuration values throughout the application.
Example
Example