Skip to content

Commit 0da1205

Browse files
author
Seth Davenport
committed
linter fixes
1 parent 9a6e91b commit 0da1205

13 files changed

+22
-24
lines changed

.angular-cli.json

+4-1
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
],

e2e/app.po.ts

+1-1
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
}

src/app/app.actions.ts

+1-1
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

+4-9
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

+1-1
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

+1-1
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

+2-2
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

+1-1
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';

src/app/feedback/feedback-form/feedback-form.component.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { Component } from '@angular/core';
22
import { Connect, FormStore } from '@angular-redux/form';
33
import { NgRedux } from '@angular-redux/store';
4-
import { Observable } from 'rxjs';
4+
import { Observable } from 'rxjs/Observable';
55
import { of } from 'rxjs/observable/of';
66

77
@Component({
@@ -18,4 +18,4 @@ export class FeedbackFormComponent {
1818
.map(comments => comments || '')
1919
.map(comments => this.MAX_COMMENT_CHARS - comments.length);
2020
}
21-
}
21+
}

src/app/feedback/feedback.module.ts

+1-1
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 { FormsModule, ReactiveFormsModule } from '@angular/forms';
33
import { CommonModule } from '@angular/common';
44
import { NgReduxFormModule } from '@angular-redux/form';

src/app/lions/lions.module.ts

+1-1
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 { LionListComponent } from './lion-list/lion-list.component';

src/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
<link rel="icon" type="image/x-icon" href="favicon.ico">
1010
</head>
1111
<body>
12-
<app-root>Loading...</app-root>
12+
<zoo-root>Loading...</zoo-root>
1313
</body>
1414
</html>

tslint.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@
9898
"check-type"
9999
],
100100

101-
"directive-selector": [true, "attribute", "app", "camelCase"],
102-
"component-selector": [true, "element", "app", "kebab-case"],
101+
"directive-selector": [true, "attribute", "zoo", "camelCase"],
102+
"component-selector": [true, "element", "zoo", "kebab-case"],
103103
"use-input-property-decorator": true,
104104
"use-output-property-decorator": true,
105105
"use-host-property-decorator": true,

0 commit comments

Comments
 (0)