-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
At current time env is accessible everywhere in project (but used only in main module).
Proposal:
- Disallow
envin eslint rules. - Add 'resolve-options' helper (allow env here).
- Add to options all missed entities. For example
const appInstallation = process.env.APP_INSTALLATION;can not be configured without env. - Reverse default behavior for
disableDotEnv - Make more options accessible from env
Proposal+:
Looks like options.config is a flat object.
Maybe it should be top level param
constructor(options: InitOptions = {}) {}
constructor(options: InitOptions & AppConfig = {}) {}
So most part of configuration will be accessible from env
# appTracingEnabled
APP_TRACING_ENABLED=false
But I understand problems with appSensitiveKeys in this keys.
Most interested api looks like:
import {NodeKit, configure} from 'nodekit';
const nodekit = new NodeKit(configure({
env: true,
file: require.resolve('./config')
}));Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
🗃️ Later