Skip to content

Code Splitting challenges with auto-generated action types #4698

Answered by markerikson
EvHaus asked this question in Help
Discussion options

You must be logged in to vote

It's always tradeoffs.

The action creators do generate predictable action names. Worst case, you decide that the bundle size aspect is too much of an issue, and hand-write the action type strings and manually annotate the TS types yourself.

That said, I'm curious - just how big are the action-related files that you're pulling in? How much are they actually adding to the bundle size in practice?

Also: how many of those async thunks could actually be replaced by use of RTK Query?

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@EvHaus
Comment options

Answer selected by EvHaus
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants