microsoft / microsoft/TypeScript
Re-exporting namespace declarations in ES6 ambient declaration
未关闭
还没有人认领这个 Issue。
In Discussion
Suggestion
- 主要语言
- Go
- 星标
- 111k
- 派生
- 14.3k
- 平均合并
- 2 天 4 小时
- 30 天内合并 PR
- 132
描述
Right now many declaration files take this form:
declare namespace MyLib {
}
declare module 'myLib' {
export = MyLib;
}
However, there doesn't seem to be an equivalent for ES6 modules:
declare module 'myLib' {
export default MyLib; // this works for exporting the default, but other exported items in MyLib are not considered to be named exports of the ES6 module
export * from MyLib; // this is essentially what I'm trying to accomplish
}
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
该 issue 没有指定任何文件或测试。先从 TypeScript 对 ambient namespace declarations 和 ES6 module exports 的处理入手,然后确定 MyLib 预期的重新导出语义。完成的标准是:命名空间成员被识别为所声明 ES6 模块的具名导出,并通过适当的编译器测试验证其行为。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- javascript, typescript
- 领域
- compilers
- Issue 类型
- 功能
- 难度
- 5/5
- 预计耗时
- 一周以上
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 20/100