api-platform / create-client

Generate React or Vue.js-based Progressive Web Apps from an Hydra-enabled API. Also support React Native.
https://api-platform.com/docs/client-generator/
MIT License
374 stars 132 forks source link

feat(next): use react-query #320

Closed malikalahfaoui closed 2 years ago

malikalahfaoui commented 2 years ago
Q A
Branch? main for features / current stable version branch for bug fixes
Tickets #...
License MIT
Doc PR api-platform/docs#...
alanpoulain commented 2 years ago

It probably lacks the usage of:

dunglas commented 2 years ago

Why React Query and not SWR... or just nothing?

alanpoulain commented 2 years ago

@dunglas IMHO, react-query is the preferred fetcher nowadays (and has more features than SWR). It was your own proposal to use a fetcher: https://github.com/api-platform/client-generator/issues/255, and I think it's a good idea since it has a very good cache system.

dunglas commented 2 years ago

Let's use react query then 👍