You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
rtkq use actual endpoint name in action.type #2995
Is there a way to use the actual endpoint name in the action type for rktq instead of api/executeQuery and api/executeMutation?
It's really hard to investigate issues with redux devtools when every dispatch is basically the same action type. I need to go through all of them and look into the payload to see which endpoint this was about, which is unfortunate.
I'd like to use the endpoint name (like createAsyncThunk does) to make this easier. Is there a way to do this?
I searched issues and docs but could not find anything about this...
This is something I've been sorta griping about for a long time, personally :)
Per @phryneas 's response, I'm not sure it is feasible to do that atm. We'd somehow have to start generating unique action types for each endpoint and change a bunch of internal logic to handle those.
Tbh. it isn't too feasible, but if it's only about the DevTools - have you tried looking into the RTK Quert tab in the devtools? You can even filter all actions for a speicifc cache entry there.
I can't use the devtools you are talking about when I am running in hermes on ReactNative. I need to use Flipper, which has a redux plugin, that does not have this pane unfortunately.... But thanks for pointing out, maybe I can find another way.
Activity
markerikson commentedon Dec 12, 2022
This is something I've been sorta griping about for a long time, personally :)
Per @phryneas 's response, I'm not sure it is feasible to do that atm. We'd somehow have to start generating unique action types for each endpoint and change a bunch of internal logic to handle those.
phryneas commentedon Dec 12, 2022
Tbh. it isn't too feasible, but if it's only about the DevTools - have you tried looking into the RTK Quert tab in the devtools? You can even filter all actions for a speicifc cache entry there.
uloco commentedon Dec 12, 2022
I can't use the devtools you are talking about when I am running in hermes on ReactNative. I need to use Flipper, which has a redux plugin, that does not have this pane unfortunately.... But thanks for pointing out, maybe I can find another way.
createApistructure and extensions #5491