me: how do i check if my object is of a given type?
typescript:
> oh we don't have a way for that, you write a function :)
```typescript
function isOfTargetType(obj: any): obj is TargetType{
return obj !== undefined
}
```

...wasn't this THE WHOLE POINT of ?? Are we any better off than just writing regular-ass javascript?

0

If you have a fediverse account, you can quote this note from your own instance. Search https://aleph.land/users/AdamRGrey/statuses/115804322579054203 on your instance and quote it. (Note that quoting is not supported in Mastodon.)