You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I came up with a slightly different solution to problem 15-intersection which follows from problem 14-extends.
interfaceUserWithPostsextendsUser{posts: Post[]}
This interface also passes the type check and it creates a slightly different code completion on WebStorm (at least)
Vs the video solution using &
There is no massive difference between the 2 but I thought I'd mention it. I imagine using the & operator with type is like using the extends with interfaces. They do the same as far as I can tell.
Thanks a ton for the great content! :)
The text was updated successfully, but these errors were encountered:
I came up with a slightly different solution to problem 15-intersection which follows from problem 14-extends.
This interface also passes the type check and it creates a slightly different code completion on WebStorm (at least)
Vs the video solution using
&
There is no massive difference between the 2 but I thought I'd mention it. I imagine using the
&
operator withtype
is like using theextends
withinterfaces
. They do the same as far as I can tell.Thanks a ton for the great content! :)
The text was updated successfully, but these errors were encountered: