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
In RTK Query's CodeGeneration, there is an issue with the generated code when encodeQueryParams is set to true. The current generated code outputs the following logic:
With this logic, if queryArg.status is '' or 0, it returns undefined, which results in the status query parameter being omitted from the request URL. However, I believe it is more natural for the values '' and 0 to be represented as ?status= and ?status=0 in query parameters. In fact, the behavior of URLSearchParams demonstrates this as follows: