These are chat archives for angular/angular-2-ionic-2

22nd
Aug 2017
alex.chengxinwen
@alexspring123
Aug 22 2017 08:28
import { Pipe, PipeTransform } from "@angular/core";

@Pipe({ name: 'ClientTalkModel' })
export class ClientTalkModelPipe implements PipeTransform {
    transform(value: string): string {
        if ('phone' == value)
            return '电话';
        else if ('go' == value)
            return '拜访';
        else if ('come' == value)
            return '来访';
        else
            return '未知';
    }
}
when execute ‘ionic serve’,got message
[16:21:02]  tslint: src/pages/brand/shared/pipes/client-talk-model.pipe.ts, line: 1
            'PipeTransform' is declared but never used.

       L1:  import { Pipe, PipeTransform } from "@angular/core";
anyone known reason?
yanxiaodi
@yanxiaodi
Aug 22 2017 11:40
@alexspring123 delete PipeTransform from your import statement.
It's just a warning.
就是说你import了,但没有用到,所以删掉就可以了
Wilgert Velinga
@wilgert
Aug 22 2017 12:48
Maybe somebody can help figure out this StackOverflow issue: https://stackoverflow.com/questions/45296988/ionic2-including-ionic-push-breaks-e2e-testing
Dave Vaughan
@rbnzdave
Aug 22 2017 20:00
@MaxGoh i just think vim has its place. I know its powerful, its a high powered lightweight ip68 sniper rifle, and is fantastic at editing text files. Maybe there is a world of pluggins, a universe, if you will, but its still shit compared to intellij if you are running in an environment that allows it to be used instead. Hell, even atom is better, and atom is a stillborn rat.