-
-
Notifications
You must be signed in to change notification settings - Fork 240
Closed
Labels
Description
Hi all, I'm trying to use pipes and I've developed my own very simplified pipe just to get things started but, I keep getting this error:
The pipe 'mypipe' could not be found
Here's the code to my pipe:
import {Pipe, PipeTransform} from '@angular/core';
@Pipe({
name: 'welcome'
})
export class WelcomePipe implements PipeTransform {
transform(value: string): string {
let message = "Welcome to " + value;
return message;
}
}
The html usage example:
[text]="'Heaven' | welcome"
In my app.module, I've tried to reference it almost everywhere (declarations, providers, etc) but with no luck. I'm also getting this problem with other components that use pipes on the html/xml side of the app.
Any ideias?