Comment

Comment by stepanvanzuriak

It's just typo, but (yes it's confusing) it work the same.

Let me explain: the name of Transition like 'INCREMENT' or 'DECREMENT' in this example have same "endpoint" - Counter itself. So in case like this there is no difference what Transition use, payload do all job (count + 1 or count - 1). So it's only important for debug (like action name in Redux).

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton