c12 icon indicating copy to clipboard operation
c12 copied to clipboard

Reflect default config in types

Open itpropro opened this issue 3 years ago • 0 comments
trafficstars

I think ResolvedConfig should not be possibly null, if a default config is present. This would make typings more intuitive, as I have to either cast or do something like this currently:

export const config = (await loadConfig<CustomConfig>({ name: 'myapp', cwd: '../', defaults })).config || defaults

itpropro avatar Nov 05 '22 18:11 itpropro