> Does the Dog class really need a static variable typed to Dog|Cat... ?
It doesn't- because classes are a native JS concept and not a TS concept; they already have the metadata to distinguish them
> TS does weird stuff like emitting functions to define enums, for instance
Not sure what's meant by this; TypeScript does introduce enum syntax which technically generates runtime code (one of the few instances), though it's just very light sugar over constants, and using it is also sorta advised against these days