style(lint): fix lint errors

This commit is contained in:
Adam Bradley
2018-03-01 16:21:06 -06:00
parent e84ddb69dc
commit 9c93df48d8
36 changed files with 313 additions and 115 deletions

View File

@ -10593,9 +10593,9 @@
}
},
"tslint-ionic-rules": {
"version": "0.0.12",
"resolved": "https://registry.npmjs.org/tslint-ionic-rules/-/tslint-ionic-rules-0.0.12.tgz",
"integrity": "sha512-CPihu6XsjinOW++UbnNrXXUi2doHtGdT00v6/v6lVY3YVujqtX/Dtbvr2s+A3Vj06Q/MliBBWV8uysabxlL1NQ==",
"version": "0.0.13",
"resolved": "https://registry.npmjs.org/tslint-ionic-rules/-/tslint-ionic-rules-0.0.13.tgz",
"integrity": "sha512-wBQbKjLlazwTW9Ql2sZYdZ04cPYCaHSdo8PuJy9Ke9d4ewyjCRweJ8AB0OKtk3MtSuNiJJumnJJYUgNGuNjevg==",
"dev": true,
"requires": {
"tslint-eslint-rules": "4.1.1"

View File

@ -28,7 +28,7 @@
"sass-lint": "^1.12.1",
"selenium-webdriver": "^3.6.0",
"tslint": "^5.8.0",
"tslint-ionic-rules": "0.0.12",
"tslint-ionic-rules": "0.0.13",
"yargs": "^10.0.3"
},
"scripts": {

View File

@ -26,7 +26,7 @@ export class Events {
* @return true if a handler was removed
*/
unsubscribe(topic: string, handler: Function = null) {
let t = this.c[topic];
const t = this.c[topic];
if (!t) {
// Wasn't found, wasn't removed
return false;
@ -39,7 +39,7 @@ export class Events {
}
// We need to find and remove a specific handler
let i = t.indexOf(handler);
const i = t.indexOf(handler);
if (i < 0) {
// Wasn't found, wasn't removed
@ -63,12 +63,12 @@ export class Events {
* @param {any} eventData the data to send as the event
*/
publish(topic: string, ...args: any[]) {
var t = this.c[topic];
const t = this.c[topic];
if (!t) {
return null;
}
let responses: any[] = [];
const responses: any[] = [];
t.forEach((handler: any) => {
responses.push(handler(...args));
});

View File

@ -1,7 +1,8 @@
{
"compilerOptions": {
"allowUnreachableCode": false,
"alwaysStrict": true,
"allowSyntheticDefaultImports": true,
"allowUnreachableCode": false,
"declaration": true,
"experimentalDecorators": true,
"forceConsistentCasingInFileNames": true,
@ -9,7 +10,7 @@
"jsxFactory": "h",
"lib": [
"dom",
"es2015"
"es2017"
],
"module": "es2015",
"moduleResolution": "node",