"i have done a couple bad things"


number of years i have lived on this earth
over 30
You must log in to comment.

in reply to @thricedotted's post:

if it fits the interface and the types aren't set up properly for you to do const app: UnsafeAppInterface then yeah, do as unknown as T. it hurts but there isn't much choice.

yeah as @noa suggested, as unknown as T is basically the typescript equivalent of reinterpret_cast<T>, which is to say it's your way of telling the typechecker "okay, even if you don't know what this is, I know it's a T so stop bugging me"