Skip to content

Instantly share code, notes, and snippets.

@kevinchisholm
Created April 1, 2020 18:15
Show Gist options
  • Save kevinchisholm/d58fbb14907b0133e034f733fe2402a4 to your computer and use it in GitHub Desktop.
Save kevinchisholm/d58fbb14907b0133e034f733fe2402a4 to your computer and use it in GitHub Desktop.
import {
Pipe,
PipeTransform
} from '@angular/core';
@Pipe({
name: 'testPipe'
})
export class TestPipePipe implements PipeTransform {
transform(value: string): string {
let newStr: string = "";
for (var i = value.length - 1; i >= 0; i--) {
newStr += value.charAt(i);
}
return newStr;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment