Reputation: 26085
class Dispatcher<TPayload> {
_callbacks: {[key: DispatchToken]: (payload: TPayload) => void}
...
It looks like TypeScript, but I'm able to compile it using Babel without TypeScript. I couldn't find anything about this in ES6 or ES7. What is this syntax called?
Upvotes: 0
Views: 51
Reputation: 62793
These are flow annotations, it's Facebook's own type checker.
Upvotes: 1