grouchymachine
Describing type for overriden config
Hi All,
In a Nuxt app that I work on we rely on config overriding and it works well with Typescript. Unfortunately I encountered problem with describing type for array configs that'll get get overriden.
This is the type for the config:
This is the initial value for it:
And this is the override:
On the override file, I get error from TS saying:
I looked into Defu type util, but I have trouble applying it.
One othe approach that was suggested is:
but it changes the type of the actual config and forces additional code around that 😦 Any help would be appreciated.
4 replies