Skip to content

Commit

Permalink
fix: template ts syntax broken with inline comments
Browse files Browse the repository at this point in the history
close #1143
  • Loading branch information
johnsoncodehk committed Apr 10, 2022
1 parent ab4ef45 commit 32f9f36
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/vue-code-gen/src/generators/template.ts
Expand Up @@ -1064,7 +1064,8 @@ export function generate(
if (forRemainStyleOrClass) {
continue;
}
tsCodeGen.addText("/* " + [prop.type, prop.name, prop.arg?.loc.source, prop.exp?.loc.source, prop.loc.source].join(", ") + " */ ");
// comment this line to avoid affect comments in prop expressions
// tsCodeGen.addText("/* " + [prop.type, prop.name, prop.arg?.loc.source, prop.exp?.loc.source, prop.loc.source].join(", ") + " */ ");
}
}

Expand Down

0 comments on commit 32f9f36

Please sign in to comment.