Skip to content

Commit fd8e351

Browse files
Merge pull request #18 from SethDavenport/chore/enable-ci
linter fixes
2 parents 9a6e91b + 2f0fc52 commit fd8e351

15 files changed

+34
-24
lines changed

.angular-cli.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"test": "test.ts",
1818
"tsconfig": "tsconfig.app.json",
1919
"testTsconfig": "tsconfig.spec.json",
20-
"prefix": "app",
20+
"prefix": "zoo",
2121
"styles": [
2222
"styles.css"
2323
],
@@ -36,12 +36,15 @@
3636
},
3737
"lint": [
3838
{
39+
"files": "src/**/*.ts",
3940
"project": "src/tsconfig.app.json"
4041
},
4142
{
43+
"files": "src/**/*.ts",
4244
"project": "src/tsconfig.spec.json"
4345
},
4446
{
47+
"files": "src/**/*.ts",
4548
"project": "e2e/tsconfig.e2e.json"
4649
}
4750
],

circle.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
machine:
2+
node:
3+
version: 6.9.5
4+
5+
test:
6+
override:
7+
- ng lint
8+
- ng test --single-run
9+
- ng e2e

e2e/app.po.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ export class AppPage {
66
}
77

88
getParagraphText() {
9-
return element(by.css('app-root h1')).getText();
9+
return element(by.css('zoo-root h1')).getText();
1010
}
1111
}

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
"lint": "ng lint",
1111
"e2e": "ng e2e"
1212
},
13+
"engines": {
14+
"node": ">=6.9.5"
15+
},
1316
"private": true,
1417
"dependencies": {
1518
"@angular-redux/form": "^6.0.1",

src/app/app.actions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ export class AppActions {
88
loadData() {
99
return {
1010
type: AppActions.LOAD_DATA
11-
}
11+
};
1212
}
1313
}

src/app/app.component.ts

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,14 @@ import { NgRedux } from '@angular-redux/store';
44
import { AppActions } from './app.actions';
55

66
@Component({
7-
selector: 'app-root',
7+
selector: 'zoo-root',
88
templateUrl: './app.component.html',
99
styleUrls: ['./app.component.css']
1010
})
1111
export class AppComponent {
1212
title = 'Welcome to the Zoo';
1313

14-
constructor(
15-
private ngRedux: NgRedux<any>,
16-
private actions: AppActions,
17-
) { }
18-
19-
ngOnInit() {
20-
this.ngRedux.dispatch(this.actions.loadData());
14+
constructor(ngRedux: NgRedux<any>, actions: AppActions) {
15+
ngRedux.dispatch(actions.loadData());
2116
}
22-
}
17+
}

src/app/core/core.module.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { NgModule } from '@angular/core'
1+
import { NgModule } from '@angular/core';
22
import { CommonModule } from '@angular/common';
33

44
import { SpinnerComponent } from './spinner/spinner.component';

src/app/elephants/elephant-list/elephant-list.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export class ElephantListComponent {
1212
// constructor(ngRedux: NgRedux {
1313
// this.elephants$ = ngRedux.select(['elephants', 'items']);
1414
// })
15-
@select(['elephants', 'items']) readonly elephants$: Observable<any[]>
15+
@select(['elephants', 'items']) readonly elephants$: Observable<any[]>;
1616
@select(['elephants', 'loading']) readonly loading$: Observable<boolean>;
1717
@select(['elephants', 'error']) readonly error$: Observable<any>;
1818

src/app/elephants/elephants.epics.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,6 @@ export class ElephantsEpics {
2626
.switchMap(a => this.service.getAll()
2727
.map(data => this.actions.loadSucceeded(data))
2828
.catch(response => of(this.actions.loadFailed({
29-
status: ''+response.status,
30-
}))));
29+
status: '' + response.status,
30+
}))))
3131
}

src/app/elephants/elephants.module.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { NgModule } from '@angular/core'
1+
import { NgModule } from '@angular/core';
22
import { CommonModule } from '@angular/common';
33

44
import { ElephantListComponent } from './elephant-list/elephant-list.component';

0 commit comments

Comments
 (0)