1.2.0
It's Mitt's first release since 2017! That's the thing about a 200 byte library - there's not a lot of code here to necessitate constant updates. Take it as a sign of stability.
This release is primarily an improvement to the TypeScript definition we ship with Mitt:
- You can now invoke
mitt()
with or withoutnew
in TypeScript (#60/#67 - thanks @davidkpiano) .on('*', handler)
now has types that pass the correct(event, data)
arguments (#76, thanks @zbuttram)- The optional
all
parameter, which lets you pass your own mapping of handler Arrays to Mitt, now has correct types (#73, thanks @jesperzach)