Skip to content

fix wrapping classes when targeting ESNext - #38566

Closed
Charles (clydin) wants to merge 1 commit into
microsoft:masterfrom
clydin:fix-class-iife-esnext
Closed

fix wrapping classes when targeting ESNext#38566
Charles (clydin) wants to merge 1 commit into
microsoft:masterfrom
clydin:fix-class-iife-esnext

Conversation

@clydin

@clydinCharles (clydin) commented May 14, 2020

Copy link
Copy Markdown
Contributor

This conforms to the behavior present in the class fields transformer:

functiontransformSourceFile(node: SourceFile){
constoptions=context.getCompilerOptions();
if(node.isDeclarationFile
||options.useDefineForClassFields&&options.target===ScriptTarget.ESNext){
returnnode;
}

Fixes#38528

Comment threadsrc/compiler/transformers/ts.ts Outdated
@clydin
Charles (clydin) deleted the fix-class-iife-esnext branch August 20, 2020 16:26
@microsoftMicrosoft (microsoft) locked as resolved and limited conversation to collaborators Oct 21, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

For Milestone BugPRs that fix a bug with a specific milestone

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Static field emit is IIFE

5 participants

@clydin@rbuckton@robpalme@sandersn@DanielRosenwasser