As in the title: does TypeScript support namespaces? If so, how do I use them?
As of version 1.5, Typescript supports namespace
keyword. Namespaces are equivalent to internal modules.
From What's new in Typescript:
Before:
module Math { export function add(x, y) { ... } }
After:
namespace Math { export function add(x, y) { ... } }
For defining an internal module, now you can use both module
and namespace
.