-
Notifications
You must be signed in to change notification settings - Fork 12.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9dc15b4
commit 42d8328
Showing
4 changed files
with
47 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
//// [exportClauseEmit.ts] | ||
var str = "Hello"; | ||
// Change str | ||
str = "Hello World!!!"; | ||
export {str}; | ||
|
||
//// [exportClauseEmit.js] | ||
var str = "Hello"; | ||
exports.str = str; | ||
// Change str | ||
str = "Hello World!!!"; | ||
|
||
|
||
//// [exportClauseEmit.d.ts] | ||
declare var str: string; | ||
export { str }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
=== tests/cases/compiler/exportClauseEmit.ts === | ||
var str = "Hello"; | ||
>str : Symbol(str, Decl(exportClauseEmit.ts, 0, 3)) | ||
|
||
// Change str | ||
str = "Hello World!!!"; | ||
>str : Symbol(str, Decl(exportClauseEmit.ts, 0, 3)) | ||
|
||
export {str}; | ||
>str : Symbol(str, Decl(exportClauseEmit.ts, 3, 8)) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
=== tests/cases/compiler/exportClauseEmit.ts === | ||
var str = "Hello"; | ||
>str : string | ||
>"Hello" : string | ||
|
||
// Change str | ||
str = "Hello World!!!"; | ||
>str = "Hello World!!!" : string | ||
>str : string | ||
>"Hello World!!!" : string | ||
|
||
export {str}; | ||
>str : string | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
//@module: commonjs | ||
//@declaration: true | ||
var str = "Hello"; | ||
// Change str | ||
str = "Hello World!!!"; | ||
export {str}; |