logoalt Hacker News

bodantogatlast Tuesday at 1:52 PM1 replyview on HN

Incredibly useful, especially with React, where the Context API, state lifting, and prop drilling often feel clunky. That said, it can lead to messy code if not carefully managed.


Replies

jilleslast Tuesday at 3:45 PM

Bingo! Having tons of `CustomEvents` with arbitrary handlers gets unwieldy. One way we "solved" this is by only allowing custom events in a `events.ts` file and document them pretty extensively.