diff --git a/modules/benchmarks/e2e_test/old/naive_infinite_scroll_spec.ts b/modules/benchmarks/e2e_test/old/naive_infinite_scroll_spec.ts
index b6b9df3dbe..86b8b493d5 100644
--- a/modules/benchmarks/e2e_test/old/naive_infinite_scroll_spec.ts
+++ b/modules/benchmarks/e2e_test/old/naive_infinite_scroll_spec.ts
@@ -49,9 +49,7 @@ describe('ng2 naive infinite scroll benchmark', function() {
firstTextOf(`${ stageButtons }:enabled`).then(function(text) {
expect(text).toEqual('Pitched');
clickFirstOf(`${ stageButtons }:enabled`).then(function() {
- firstTextOf(`${ stageButtons }:enabled`).then(function(text) {
- expect(text).toEqual('Won');
- })
+ firstTextOf(`${ stageButtons }:enabled`).then((text) => expect(text).toEqual('Won'));
});
});
diff --git a/modules/benchmarks_external/src/compiler/compiler_benchmark.ts b/modules/benchmarks_external/src/compiler/compiler_benchmark.ts
index c04a928396..6d661efba8 100644
--- a/modules/benchmarks_external/src/compiler/compiler_benchmark.ts
+++ b/modules/benchmarks_external/src/compiler/compiler_benchmark.ts
@@ -39,7 +39,7 @@ angular.module('app', [])
return {
compile: function($element, $attrs) {
var expr = $parse($attrs.attr0);
- return function($scope) { $scope.$watch(expr, angular.noop); }
+ return ($scope) => $scope.$watch(expr, angular.noop);
}
};
}
@@ -51,7 +51,7 @@ angular.module('app', [])
return {
compile: function($element, $attrs) {
var expr = $parse($attrs.attr1);
- return function($scope) { $scope.$watch(expr, angular.noop); }
+ return ($scope) => $scope.$watch(expr, angular.noop);
}
};
}
@@ -63,7 +63,7 @@ angular.module('app', [])
return {
compile: function($element, $attrs) {
var expr = $parse($attrs.attr2);
- return function($scope) { $scope.$watch(expr, angular.noop); }
+ return ($scope) => $scope.$watch(expr, angular.noop);
}
};
}
@@ -75,7 +75,7 @@ angular.module('app', [])
return {
compile: function($element, $attrs) {
var expr = $parse($attrs.attr3);
- return function($scope) { $scope.$watch(expr, angular.noop); }
+ return ($scope) => $scope.$watch(expr, angular.noop);
}
};
}
@@ -87,7 +87,7 @@ angular.module('app', [])
return {
compile: function($element, $attrs) {
var expr = $parse($attrs.attr4);
- return function($scope) { $scope.$watch(expr, angular.noop); }
+ return ($scope) => $scope.$watch(expr, angular.noop);
}
};
}
diff --git a/modules/benchmarks_external/src/largetable/largetable_benchmark.ts b/modules/benchmarks_external/src/largetable/largetable_benchmark.ts
index 8446c60bab..140f73bf19 100644
--- a/modules/benchmarks_external/src/largetable/largetable_benchmark.ts
+++ b/modules/benchmarks_external/src/largetable/largetable_benchmark.ts
@@ -116,4 +116,4 @@ angular.module('app', [])
}
}
};
- })
+ });
diff --git a/modules/benchmarks_external/src/static_tree/tree_benchmark.ts b/modules/benchmarks_external/src/static_tree/tree_benchmark.ts
index e567f7f8d3..8b849767b5 100644
--- a/modules/benchmarks_external/src/static_tree/tree_benchmark.ts
+++ b/modules/benchmarks_external/src/static_tree/tree_benchmark.ts
@@ -19,7 +19,7 @@ export function main() {
function addTreeDirective(module, level: number) {
var template;
if (level <= 0) {
- template = ` {{data.value}}`
+ template = ` {{data.value}}`;
} else {
template = ` {{data.value}} `;
}
diff --git a/modules/benchmarks_external/src/tree/react/index.ts b/modules/benchmarks_external/src/tree/react/index.ts
index ef0912fafa..010970f836 100644
--- a/modules/benchmarks_external/src/tree/react/index.ts
+++ b/modules/benchmarks_external/src/tree/react/index.ts
@@ -19,13 +19,13 @@ var TreeComponent = React.createClass({
var left = null;
if (treeNode.left) {
left = React.createElement(
- "span", {}, [React.createElement(TreeComponent, {treeNode: treeNode.left}, "")])
+ "span", {}, [React.createElement(TreeComponent, {treeNode: treeNode.left}, "")]);
}
var right = null;
if (treeNode.right) {
right = React.createElement(
- "span", {}, [React.createElement(TreeComponent, {treeNode: treeNode.right}, "")])
+ "span", {}, [React.createElement(TreeComponent, {treeNode: treeNode.right}, "")]);
}
var span = React.createElement("span", {}, [" " + treeNode.value, left, right]);
diff --git a/modules/benchmarks_external/src/tree/tree_benchmark.ts b/modules/benchmarks_external/src/tree/tree_benchmark.ts
index af84cc8332..2641f2e84a 100644
--- a/modules/benchmarks_external/src/tree/tree_benchmark.ts
+++ b/modules/benchmarks_external/src/tree/tree_benchmark.ts
@@ -57,10 +57,10 @@ angular.module('app', [])
function(clone) { $element.append(clone); });
}
});
- }
+ };
}
- }
+ };
}
])
.config([
diff --git a/modules/playground/src/async/index.ts b/modules/playground/src/async/index.ts
index 704d64e0b3..f109e758b2 100644
--- a/modules/playground/src/async/index.ts
+++ b/modules/playground/src/async/index.ts
@@ -73,7 +73,7 @@ class AsyncApplication {
periodicIncrement(): void {
this.cancelPeriodicIncrement();
- this.intervalId = setInterval(() => { this.val4++; }, 2000)
+ this.intervalId = setInterval(() => this.val4++, 2000);
};
cancelDelayedIncrement(): void {
diff --git a/modules/playground/src/routing/app/data.ts b/modules/playground/src/routing/app/data.ts
index 81ba71fc0c..02376c9684 100644
--- a/modules/playground/src/routing/app/data.ts
+++ b/modules/playground/src/routing/app/data.ts
@@ -2121,4 +2121,4 @@ export var data = [
'subject': 'Fwd: wedding photos',
'draft': true
}
-]
+];
diff --git a/tools/@angular/tsc-wrapped/src/collector.ts b/tools/@angular/tsc-wrapped/src/collector.ts
index 8d66823a6f..28db8f5b63 100644
--- a/tools/@angular/tsc-wrapped/src/collector.ts
+++ b/tools/@angular/tsc-wrapped/src/collector.ts
@@ -240,7 +240,7 @@ export class MetadataCollector {
moduleExport.export = exportDeclaration.exportClause.elements.map(
element => element.propertyName ?
{name: element.propertyName.text, as: element.name.text} :
- element.name.text)
+ element.name.text);
}
if (!exports) exports = [];
exports.push(moduleExport);
@@ -300,7 +300,7 @@ export class MetadataCollector {
__symbolic: 'select',
expression: recordEntry({__symbolic: 'reference', name: enumName}, node), name
}
- }
+ };
} else {
nextDefaultValue =
recordEntry(errorSym('Unsuppported enum member name', member.name), node);
@@ -517,7 +517,7 @@ function validateMetadata(
const entry = metadata[name];
try {
if (isClassMetadata(entry)) {
- validateClass(entry)
+ validateClass(entry);
}
} catch (e) {
const node = nodeMap.get(entry);
diff --git a/tools/@angular/tsc-wrapped/src/evaluator.ts b/tools/@angular/tsc-wrapped/src/evaluator.ts
index 7bb6cbed6b..db699e68c1 100644
--- a/tools/@angular/tsc-wrapped/src/evaluator.ts
+++ b/tools/@angular/tsc-wrapped/src/evaluator.ts
@@ -65,7 +65,7 @@ export interface ImportMetadata {
function getSourceFileOfNode(node: ts.Node): ts.SourceFile {
while (node && node.kind != ts.SyntaxKind.SourceFile) {
- node = node.parent
+ node = node.parent;
}
return node;
}
@@ -383,7 +383,7 @@ export class Evaluator {
module: left.module,
name: qualifiedName.right.text
},
- node)
+ node);
}
// Record a type reference to a declared type as a select.
return {__symbolic: 'select', expression: left, member: qualifiedName.right.text};
diff --git a/tools/@angular/tsc-wrapped/src/schema.ts b/tools/@angular/tsc-wrapped/src/schema.ts
index 22763e3120..60bd6db840 100644
--- a/tools/@angular/tsc-wrapped/src/schema.ts
+++ b/tools/@angular/tsc-wrapped/src/schema.ts
@@ -96,7 +96,7 @@ export interface MetadataObject { [name: string]: MetadataValue; }
export interface MetadataArray { [name: number]: MetadataValue; }
export interface MetadataSymbolicExpression {
- __symbolic: 'binary'|'call'|'index'|'new'|'pre'|'reference'|'select'|'spread'|'if'
+ __symbolic: 'binary'|'call'|'index'|'new'|'pre'|'reference'|'select'|'spread'|'if';
}
export function isMetadataSymbolicExpression(value: any): value is MetadataSymbolicExpression {
if (value) {
diff --git a/tools/@angular/tsc-wrapped/test/collector.spec.ts b/tools/@angular/tsc-wrapped/test/collector.spec.ts
index 2eab24742e..7b2d5201ee 100644
--- a/tools/@angular/tsc-wrapped/test/collector.spec.ts
+++ b/tools/@angular/tsc-wrapped/test/collector.spec.ts
@@ -550,7 +550,7 @@ describe('Collector', () => {
arguments: [{providers: [{__symbolic: 'reference', name: 'REQUIRED_VALIDATOR'}]}]
}]
}
- })
+ });
});
it('should collect an error for a simple function that references a local variable', () => {
@@ -568,7 +568,7 @@ describe('Collector', () => {
context: {name: 'localSymbol'}
}
}
- })
+ });
});
describe('in strict mode', () => {
@@ -588,7 +588,7 @@ describe('Collector', () => {
expect(() => collector.getMetadata(unsupported1, true))
.toThrowError(/Reference to non-exported class/);
});
- })
+ });
});
// TODO: Do not use \` in a template literal as it confuses clang-format
diff --git a/tools/@angular/tsc-wrapped/test/symbols.spec.ts b/tools/@angular/tsc-wrapped/test/symbols.spec.ts
index 2e1177165a..43f1f8c242 100644
--- a/tools/@angular/tsc-wrapped/test/symbols.spec.ts
+++ b/tools/@angular/tsc-wrapped/test/symbols.spec.ts
@@ -57,7 +57,7 @@ describe('Symbols', () => {
it('should be able to find the source files', () => {
expect(expressions).toBeDefined();
expect(imports).toBeDefined();
- })
+ });
it('should be able to create symbols for a source file', () => {
let symbols = new Symbols(expressions);
diff --git a/tools/tsc-watch/tsc_watch.ts b/tools/tsc-watch/tsc_watch.ts
index c5e62b8015..f262e47ece 100644
--- a/tools/tsc-watch/tsc_watch.ts
+++ b/tools/tsc-watch/tsc_watch.ts
@@ -114,8 +114,7 @@ export class TscWatch {
} else {
if (this.triggered) {
this.triggered.then(
- () => this.triggerCmds(),
- (e) => {console.log('Error while running commands....', e)});
+ () => this.triggerCmds(), (e) => console.log('Error while running commands....', e));
} else {
this.triggerCmds();
}
@@ -127,9 +126,9 @@ export class TscWatch {
triggerCmds() {
var cmdPromise: Promise = Promise.resolve(0);
- this.onChangeCmds.forEach((cmd: string[] | Command) => {cmdPromise = cmdPromise.then(() => {
- return this.runCmd(cmd);
- })});
+ this.onChangeCmds.forEach(
+ (cmd: string[] | Command) => cmdPromise =
+ cmdPromise.then(() => this.runCmd(cmd)));
cmdPromise.then(() => this.triggered = null, (code) => {
if (this.runOnce) {
if (typeof code != 'number') {
diff --git a/tools/typings-test/include-all.ts b/tools/typings-test/include-all.ts
index fb5b5466c7..7d176df731 100644
--- a/tools/typings-test/include-all.ts
+++ b/tools/typings-test/include-all.ts
@@ -36,4 +36,4 @@ export default {
router,
routerTesting,
upgrade
-}
+};