File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ import { Pipe , PipeTransform } from '@angular/core' ;
2+ import { toBoolean } from '../helpers/to-boolean' ;
3+ import { BooleanLike } from '../models/boolean-like' ;
4+
5+ @Pipe ( {
6+ name : 'toBoolean'
7+ } )
8+ export class ToBooleanPipe implements PipeTransform {
9+ public transform ( value : BooleanLike ) : boolean {
10+ return toBoolean ( value ) ;
11+ }
12+ }
Original file line number Diff line number Diff line change @@ -199,6 +199,7 @@ export * from './lib/pipes/round.pipe';
199199export * from './lib/pipes/safe.pipe' ;
200200export * from './lib/pipes/slice.pipe' ;
201201export * from './lib/pipes/title.pipe' ;
202+ export * from './lib/pipes/to-boolean.pipe' ;
202203export * from './lib/pipes/validation.pipe' ;
203204export * from './lib/services/base-href.service' ;
204205export * from './lib/services/environment.service' ;
You can’t perform that action at this time.
0 commit comments