Created
June 26, 2017 13:42
-
-
Save t8g/a7706cbc739e21dd4865e8e5ac4b23af to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Pipe, PipeTransform } from '@angular/core'; | |
@Pipe({ | |
name: 'reverse' | |
}) | |
export class ReversePipe implements PipeTransform { | |
transform(value: string): string { | |
return value.split('').reverse().join(''); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment