-
-
Notifications
You must be signed in to change notification settings - Fork 14
Description
Describe the feature
Would it be possible to extend functionality so that /api/__api_party/${endpointId} routes can be cached in nitro by routeRules that we can define in nuxt.config.ts?
I don't have much knowledge about the inner workings of Nuxt and Nitro so maybe this is not possible to modules but it seems like this would be a great benefit.
Currently in my project I have a bunch for endpoints delivering some SEO content that I would like to cache for an extended period of time. Currently it doesn't seem possible to use the api-party composables fetch this data and have it cached by Nitro. This means I have to manually create endpoints in my server/api folder and use a mix of useFetch for cacheable endpoints and api-party composables for non-cachable endpoints which leads to a very confusing DX.
Additional information
- Would you be willing to help implement this feature?
- Can you think of other implementations of this feature?
Final checks
- Check existing issues.