News for hackers. Stuff that matters.
Re:Twenty five thousand dollars of funny money by roflyear on Saturday December 03, 2022 @09:33PM (#33849975)
I don't think it is possible in Typescript, but in other languages you can do assertations about custom types. Like

assert istype(whatever, MyCustomType)

Which would throw an exception if whatever is not a "MyCustomType" at runtime.

There are no comments on this comment yet.