Skip to content

Commit

Permalink
Print semicolon for accessor and add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sosukesuzuki committed Nov 30, 2022
1 parent 151b2af commit e094ef3
Show file tree
Hide file tree
Showing 4 changed files with 366 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/language-js/print/statement.js
Expand Up @@ -179,7 +179,10 @@ function shouldPrintSemicolonAfterClassProperty(node, nextNode) {
// this isn't actually possible yet with most parsers available today
// so isn't properly tested yet.
if (
(name === "static" || name === "get" || name === "set") &&
(name === "static" ||
name === "get" ||
name === "set" ||
name === "accessor") &&
!node.value &&
!node.typeAnnotation
) {
Expand Down

0 comments on commit e094ef3

Please sign in to comment.