Align AST for TSEnumDeclaration with TSInterfaceDeclaration, TSModuleDeclaration, etc #1305
Labels
accepting prs
Go ahead, send a pull request that resolves this issue
breaking change
This change will require a new major version to be released
enhancement
New feature or request
locked due to age
Please open a new issue if you'd like to say more. See https://typescript-eslint.io/contributing.
package: typescript-estree
Issues related to @typescript-eslint/typescript-estree
Milestone
For each
TSEnumDeclaration
, we place its members directly on this AST node.For each
TSInterfaceDeclaration
, we have a separateTSInterfaceBody
node, upon which we place the members.I'm not sure why there's this inconsistency between the two, but I think we should consider aligning the two.
I'm not sure why
TSEnumDeclaration
was created without a body, but I think that creating aTSEnumBody
node seems like the correct thing to do.Doing so would align it with not only
TSInterfaceDeclaration
, but alsoTSModuleDeclaration
,ClassDeclaration
andFunctionDeclaration
.The text was updated successfully, but these errors were encountered: