Skip to content

Commit ac8e4dc

Browse files
manucorporatadamdbradley
authored andcommitted
style(all): tslinter warnings
1 parent 324f2cb commit ac8e4dc

File tree

166 files changed

+872
-872
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

166 files changed

+872
-872
lines changed

demos/infinite-scroll/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {Component, Injectable} from '@angular/core';
2-
import {ionicBootstrap, InfiniteScroll} from 'ionic-angular';
1+
import { Component, Injectable } from '@angular/core';
2+
import { ionicBootstrap, InfiniteScroll } from 'ionic-angular';
33

44

55
/**
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
export { x as y} from './privateModule';
1+
export { x as y } from './privateModule';
22

33
export abstract class AbstractClass {}

scripts/docs/typescript-package/services/tsParser/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ module.exports = function tsParser(createCompilerHost, log) {
4848
tsModule.exportArray = typeChecker.getExportsOfModule(tsModule);
4949

5050
// Although 'star' imports (e.g. `export * from 'some/module';) get resolved automatically
51-
// by the compiler/binder, it seems that explicit imports (e.g. `export {SomeClass} from 'some/module'`)
51+
// by the compiler/binder, it seems that explicit imports (e.g. `export { SomeClass } from 'some/module'`)
5252
// do not so we have to do a little work.
5353
tsModule.exportArray.forEach(function(moduleExport) {
5454
if (moduleExport.flags & ts.SymbolFlags.Alias) {

src/animations/animation.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {CSS, rafFrames, transitionEnd, nativeTimeout} from '../util/dom';
2-
import {assign, isDefined} from '../util/util';
1+
import { CSS, rafFrames, transitionEnd, nativeTimeout } from '../util/dom';
2+
import { assign, isDefined } from '../util/util';
33

44

55
/**

src/animations/builtins.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
import {Animation} from './animation';
2+
import { Animation } from './animation';
33

44

55
class SlideIn extends Animation {

src/components/action-sheet/action-sheet.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ export class ActionSheet extends ViewController {
108108
*
109109
* @usage
110110
* ```ts
111-
* import {ActionSheetController} from 'ionic-angular'
111+
* import { ActionSheetController } from 'ionic-angular'
112112
*
113113
* export class MyClass{
114114
*

src/components/alert/test/dismiss/index.ts

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export class E2EPage {
1010

1111
constructor(private alertCtrl: AlertController, private nav: NavController) {}
1212

13-
submit() {
13+
submit() {
1414
var alert = this.alertCtrl.create({
1515
title: 'Not logged in',
1616
message: 'Sign in to continue.',
@@ -30,7 +30,7 @@ export class E2EPage {
3030
});
3131

3232
alert.present();
33-
}
33+
}
3434
}
3535

3636
@Component({
@@ -42,18 +42,18 @@ export class E2EPage {
4242
</ion-header>
4343
<ion-content padding>
4444
<form [formGroup]="form" (ngSubmit)="submit(form.value)">
45-
<ion-list>
46-
<ion-item [class.error]="!form.controls.name.valid && form.controls.name.touched">
47-
<ion-label>Name</ion-label>
48-
<ion-input type="text" [(formControl)]="form.controls.name"></ion-input>
49-
</ion-item>
50-
</ion-list>
51-
<div padding style="padding-top: 0 !important;">
52-
<button list-item primary block>
53-
Submit
54-
</button>
55-
</div>
56-
</form>
45+
<ion-list>
46+
<ion-item [class.error]="!form.controls.name.valid && form.controls.name.touched">
47+
<ion-label>Name</ion-label>
48+
<ion-input type="text" [(formControl)]="form.controls.name"></ion-input>
49+
</ion-item>
50+
</ion-list>
51+
<div padding style="padding-top: 0 !important;">
52+
<button list-item primary block>
53+
Submit
54+
</button>
55+
</div>
56+
</form>
5757
<p>
5858
<button block (click)="doFastPop()">Fast Loading Dismiss, Nav Pop</button>
5959
</p>
@@ -63,27 +63,27 @@ export class E2EPage {
6363
class AnotherPage {
6464
form: ControlGroup;
6565

66-
constructor(private nav: NavController, private alertCtrl: AlertController, private loadingCtrl: LoadingController, private builder: FormBuilder) {
67-
this.form = builder.group({
68-
name: builder.control('', Validators.compose([
69-
Validators.required,
70-
Validators.minLength(5)
71-
]))
72-
});
73-
}
74-
75-
submit(value: any): void {
76-
if (this.form.valid) {
77-
console.log(value);
78-
79-
} else {
80-
this.alertCtrl.create({
81-
title: 'Invalid input data',
82-
subTitle: "Please correct the errors and resubmit the data.",
83-
buttons: [ 'OK' ]
84-
}).present();
85-
}
86-
}
66+
constructor(private nav: NavController, private alertCtrl: AlertController, private loadingCtrl: LoadingController, private builder: FormBuilder) {
67+
this.form = builder.group({
68+
name: builder.control('', Validators.compose([
69+
Validators.required,
70+
Validators.minLength(5)
71+
]))
72+
});
73+
}
74+
75+
submit(value: any): void {
76+
if (this.form.valid) {
77+
console.log(value);
78+
79+
} else {
80+
this.alertCtrl.create({
81+
title: 'Invalid input data',
82+
subTitle: 'Please correct the errors and resubmit the data.',
83+
buttons: ['OK']
84+
}).present();
85+
}
86+
}
8787

8888
ionViewDidEnter() {
8989
this.showConfirm();

src/components/app/test/animations/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {Component} from '@angular/core';
2-
import {ionicBootstrap, Config, Animation} from '../../../../../src';
1+
import { Component } from '@angular/core';
2+
import { ionicBootstrap, Config, Animation } from '../../../../../src';
33

44

55
@Component({
@@ -13,7 +13,7 @@ class E2EPage {
1313
this.duration = '1000';
1414
this.easing = 'ease-in-out';
1515

16-
console.log('isProd', config.prodMode);
16+
console.log('isProd', config.getBoolean('prodMode'));
1717
}
1818

1919
playGreen() {
@@ -39,9 +39,9 @@ class E2EPage {
3939

4040
let a = new Animation('.green');
4141
a.fromTo('translateX', '0px', '200px');
42-
a.duration(self.duration);
42+
a.duration(parseInt(self.duration));
4343
a.easing(self.easing);
44-
a.onFinish((animation) => {
44+
a.onFinish((animation: Animation) => {
4545
setTimeout(() => {
4646
play();
4747
}, 100);

src/components/app/test/cordova/index.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
import {Component} from '@angular/core';
2-
import {ionicBootstrap, NavController, ModalController, ViewController} from '../../../../../src';
3-
import {Injectable} from '@angular/core';
1+
import { Component } from '@angular/core';
2+
import { ionicBootstrap, NavController, ModalController, ViewController } from '../../../../../src';
3+
import { Injectable } from '@angular/core';
44

55

66
@Injectable()
77
export class SomeData {
88
constructor() {}
99

1010
getData() {
11-
return "SomeData";
11+
return 'SomeData';
1212
}
1313
}
1414

@@ -17,7 +17,7 @@ export class OtherData {
1717
constructor() {}
1818

1919
getData() {
20-
return "OtherData";
20+
return 'OtherData';
2121
}
2222
}
2323

@@ -61,8 +61,8 @@ class Page1 {
6161
sort: string = 'all';
6262

6363
constructor(private nav: NavController, private someData: SomeData, private otherData: OtherData) {
64-
console.log("Got some data from", someData.getData());
65-
console.log("Got some data from", otherData.getData());
64+
console.log('Got some data from', someData.getData());
65+
console.log('Got some data from', otherData.getData());
6666
}
6767

6868
goToTabs() {

src/components/app/test/gestures/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import {Component} from '@angular/core';
2-
import {ionicBootstrap} from '../../../../../src';
1+
import { Component } from '@angular/core';
2+
import { ionicBootstrap } from '../../../../../src';
33

44

55
@Component({

0 commit comments

Comments
 (0)