Make namespace parameter have default value of false to allow use of CommonJS without issues
Add namespace support for all types
Add tests for formatToType