The extends keyword on typescript can be confusing sometimes since it holds different meanings based on the context.
→ It can be used for the inheritance of interfaces.
→ But it can also be used to constrain a generic type.
Learn the key concepts that you need to unlock the powers of typescript in this article https://egghead.io/blog/learn-the-key...
Check more similar content on my site https://matiashernandez.dev
or by following me on twitter / matiasfha