Wrapping $fetch in composable with default options while retaining type safety
I managed to get autocomplete for the routes, but the return type is unknown. How can I get the return type working ? Example:
1 Reply
I found this somewhere in the nitro sourcecode:
So I changed my composable to:
And it seems to work on first look. Maybe someone from the team can confirm if this is valid ?