Some handy utilities I wrote in TypeScript - so you don't have to! Fixes and enhancements happily accepted.