Skip to content

Commit

Permalink
fix(v5-builder): stop transforming "declare" classes (#2503)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolashenry authored and ihadeed committed May 10, 2018
1 parent db32d2d commit 6662234
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/build/transformers/plugin-class.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ function transformClasses(
return ts.visitEachChild(
file,
node => {
if (node.kind !== ts.SyntaxKind.ClassDeclaration) {
if (node.kind !== ts.SyntaxKind.ClassDeclaration
|| (node.modifiers && node.modifiers.find(v => v.kind === ts.SyntaxKind.DeclareKeyword))) {
return node;
}
return transformClass(node, ngcBuild);
Expand Down

0 comments on commit 6662234

Please sign in to comment.