diff --git a/ponyracer/.angular-cli.json b/ponyracer/.angular-cli.json
index 0035b1618..3cf066277 100644
--- a/ponyracer/.angular-cli.json
+++ b/ponyracer/.angular-cli.json
@@ -36,13 +36,16 @@
},
"lint": [
{
- "project": "src/tsconfig.app.json"
+ "project": "src/tsconfig.app.json",
+ "exclude": "**/node_modules/**"
},
{
- "project": "src/tsconfig.spec.json"
+ "project": "src/tsconfig.spec.json",
+ "exclude": "**/node_modules/**"
},
{
- "project": "e2e/tsconfig.e2e.json"
+ "project": "e2e/tsconfig.e2e.json",
+ "exclude": "**/node_modules/**"
}
],
"test": {
diff --git a/ponyracer/e2e/app.e2e-spec.ts b/ponyracer/e2e/app.e2e-spec.ts
index 605376d44..e7ea74bb8 100644
--- a/ponyracer/e2e/app.e2e-spec.ts
+++ b/ponyracer/e2e/app.e2e-spec.ts
@@ -1,14 +1,14 @@
-import { PonyracerPage } from './app.po';
+import { AppPage } from './app.po';
describe('ponyracer App', () => {
- let page: PonyracerPage;
+ let page: AppPage;
beforeEach(() => {
- page = new PonyracerPage();
+ page = new AppPage();
});
it('should display welcome message', () => {
page.navigateTo();
- expect(page.getParagraphText()).toEqual('Welcome to app!!');
+ expect(page.getParagraphText()).toEqual('Welcome to app!');
});
});
diff --git a/ponyracer/e2e/app.po.ts b/ponyracer/e2e/app.po.ts
index 203cd9191..82ea75ba5 100644
--- a/ponyracer/e2e/app.po.ts
+++ b/ponyracer/e2e/app.po.ts
@@ -1,6 +1,6 @@
import { browser, by, element } from 'protractor';
-export class PonyracerPage {
+export class AppPage {
navigateTo() {
return browser.get('/');
}
diff --git a/ponyracer/e2e/tsconfig.e2e.json b/ponyracer/e2e/tsconfig.e2e.json
index e2a9a2fc7..1d9e5edf0 100644
--- a/ponyracer/e2e/tsconfig.e2e.json
+++ b/ponyracer/e2e/tsconfig.e2e.json
@@ -2,10 +2,12 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/e2e",
+ "baseUrl": "./",
"module": "commonjs",
"target": "es5",
"types": [
"jasmine",
+ "jasminewd2",
"node"
]
}
diff --git a/ponyracer/karma.conf.js b/ponyracer/karma.conf.js
index 4d9ab9d94..af139fada 100644
--- a/ponyracer/karma.conf.js
+++ b/ponyracer/karma.conf.js
@@ -1,5 +1,5 @@
// Karma configuration file, see link for more information
-// https://karma-runner.github.io/0.13/config/configuration-file.html
+// https://karma-runner.github.io/1.0/config/configuration-file.html
module.exports = function (config) {
config.set({
diff --git a/ponyracer/package.json b/ponyracer/package.json
index af6663828..b2d67b743 100644
--- a/ponyracer/package.json
+++ b/ponyracer/package.json
@@ -12,26 +12,27 @@
},
"private": true,
"dependencies": {
- "@angular/animations": "^4.0.0",
- "@angular/common": "^4.0.0",
- "@angular/compiler": "^4.0.0",
- "@angular/core": "^4.0.0",
- "@angular/forms": "^4.0.0",
- "@angular/http": "^4.0.0",
- "@angular/platform-browser": "^4.0.0",
- "@angular/platform-browser-dynamic": "^4.0.0",
- "@angular/router": "^4.0.0",
+ "@angular/animations": "^4.2.4",
+ "@angular/common": "^4.2.4",
+ "@angular/compiler": "^4.2.4",
+ "@angular/core": "^4.2.4",
+ "@angular/forms": "^4.2.4",
+ "@angular/http": "^4.2.4",
+ "@angular/platform-browser": "^4.2.4",
+ "@angular/platform-browser-dynamic": "^4.2.4",
+ "@angular/router": "^4.2.4",
"core-js": "^2.4.1",
- "rxjs": "^5.1.0",
- "zone.js": "^0.8.4"
+ "rxjs": "^5.4.2",
+ "zone.js": "^0.8.14"
},
"devDependencies": {
- "@angular/cli": "1.1.3",
- "@angular/compiler-cli": "^4.0.0",
- "@angular/language-service": "^4.0.0",
- "@types/jasmine": "2.5.45",
+ "@angular/cli": "1.4.0",
+ "@angular/compiler-cli": "^4.2.4",
+ "@angular/language-service": "^4.2.4",
+ "@types/jasmine": "~2.5.53",
+ "@types/jasminewd2": "~2.0.2",
"@types/node": "~6.0.60",
- "codelyzer": "~3.0.1",
+ "codelyzer": "~3.2.0",
"jasmine-core": "~2.6.2",
"jasmine-spec-reporter": "~4.1.0",
"karma": "~1.7.0",
@@ -41,8 +42,8 @@
"karma-jasmine": "~1.1.0",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.1.2",
- "ts-node": "~3.0.4",
- "tslint": "~5.3.2",
+ "ts-node": "~3.2.0",
+ "tslint": "~5.7.0",
"typescript": "~2.3.3"
}
}
diff --git a/ponyracer/src/app/app.component.html b/ponyracer/src/app/app.component.html
index b41bbe4be..46d517b68 100644
--- a/ponyracer/src/app/app.component.html
+++ b/ponyracer/src/app/app.component.html
@@ -1,20 +1,20 @@
-
+
- Welcome to {{title}}!!
+ Welcome to {{title}}!
-

+
Here are some links to help you start:
diff --git a/ponyracer/src/app/app.component.spec.ts b/ponyracer/src/app/app.component.spec.ts
index 7d2799ceb..bcbdf36b3 100644
--- a/ponyracer/src/app/app.component.spec.ts
+++ b/ponyracer/src/app/app.component.spec.ts
@@ -1,7 +1,5 @@
import { TestBed, async } from '@angular/core/testing';
-
import { AppComponent } from './app.component';
-
describe('AppComponent', () => {
beforeEach(async(() => {
TestBed.configureTestingModule({
@@ -10,23 +8,20 @@ describe('AppComponent', () => {
],
}).compileComponents();
}));
-
it('should create the app', async(() => {
const fixture = TestBed.createComponent(AppComponent);
const app = fixture.debugElement.componentInstance;
expect(app).toBeTruthy();
}));
-
it(`should have as title 'app'`, async(() => {
const fixture = TestBed.createComponent(AppComponent);
const app = fixture.debugElement.componentInstance;
expect(app.title).toEqual('app');
}));
-
it('should render title in a h1 tag', async(() => {
const fixture = TestBed.createComponent(AppComponent);
fixture.detectChanges();
const compiled = fixture.debugElement.nativeElement;
- expect(compiled.querySelector('h1').textContent).toContain('Welcome to app!!');
+ expect(compiled.querySelector('h1').textContent).toContain('Welcome to app!');
}));
});
diff --git a/ponyracer/src/main.ts b/ponyracer/src/main.ts
index a9ca1caf8..91ec6da5f 100644
--- a/ponyracer/src/main.ts
+++ b/ponyracer/src/main.ts
@@ -8,4 +8,5 @@ if (environment.production) {
enableProdMode();
}
-platformBrowserDynamic().bootstrapModule(AppModule);
+platformBrowserDynamic().bootstrapModule(AppModule)
+ .catch(err => console.log(err));
diff --git a/ponyracer/src/polyfills.ts b/ponyracer/src/polyfills.ts
index fd01cc9f1..581aadfea 100644
--- a/ponyracer/src/polyfills.ts
+++ b/ponyracer/src/polyfills.ts
@@ -37,16 +37,15 @@
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
// import 'classlist.js'; // Run `npm install --save classlist.js`.
-/** IE10 and IE11 requires the following to support `@angular/animation`. */
-// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
-
-
/** Evergreen browsers require these. **/
import 'core-js/es6/reflect';
import 'core-js/es7/reflect';
-/** ALL Firefox browsers require the following to support `@angular/animation`. **/
+/**
+ * Required to support Web Animations `@angular/platform-browser/animations`.
+ * Needed for: All but Chrome, Firefox and Opera. http://caniuse.com/#feat=web-animation
+ **/
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
diff --git a/ponyracer/src/tsconfig.app.json b/ponyracer/src/tsconfig.app.json
index 5e2507db5..39ba8dbac 100644
--- a/ponyracer/src/tsconfig.app.json
+++ b/ponyracer/src/tsconfig.app.json
@@ -2,8 +2,8 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/app",
+ "baseUrl": "./",
"module": "es2015",
- "baseUrl": "",
"types": []
},
"exclude": [
diff --git a/ponyracer/src/tsconfig.spec.json b/ponyracer/src/tsconfig.spec.json
index 510e3f1fd..63d89ff28 100644
--- a/ponyracer/src/tsconfig.spec.json
+++ b/ponyracer/src/tsconfig.spec.json
@@ -2,9 +2,9 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/spec",
+ "baseUrl": "./",
"module": "commonjs",
"target": "es5",
- "baseUrl": "",
"types": [
"jasmine",
"node"
diff --git a/ponyracer/tsconfig.json b/ponyracer/tsconfig.json
index a35a8ee3a..a6c016bf3 100644
--- a/ponyracer/tsconfig.json
+++ b/ponyracer/tsconfig.json
@@ -2,7 +2,6 @@
"compileOnSave": false,
"compilerOptions": {
"outDir": "./dist/out-tsc",
- "baseUrl": "src",
"sourceMap": true,
"declaration": false,
"moduleResolution": "node",
@@ -13,7 +12,7 @@
"node_modules/@types"
],
"lib": [
- "es2016",
+ "es2017",
"dom"
]
}
diff --git a/ponyracer/tslint.json b/ponyracer/tslint.json
index dd117b387..b6e591b2b 100644
--- a/ponyracer/tslint.json
+++ b/ponyracer/tslint.json
@@ -31,8 +31,14 @@
"member-access": false,
"member-ordering": [
true,
- "static-before-instance",
- "variables-before-functions"
+ {
+ "order": [
+ "static-field",
+ "instance-field",
+ "static-method",
+ "instance-method"
+ ]
+ }
],
"no-arg": true,
"no-bitwise": true,
@@ -80,6 +86,7 @@
],
"radix": true,
"semicolon": [
+ true,
"always"
],
"triple-equals": [
@@ -128,8 +135,6 @@
"use-pipe-transform-interface": true,
"component-class-suffix": true,
"directive-class-suffix": true,
- "no-access-missing-member": true,
- "templates-use-public": true,
"invoke-injectable": true
}
}