基本功能同 JS 的 module 一样

扩展的功能

可以导入导出类型:

// 导出类型:
type Bool = true | false;
 
export { Bool };
 
// 导入类型:
import { Bool } from './a';
 
let foo:Bool = true;