X Tutup
Skip to content

Commit fc016b5

Browse files
sduquejvicb
authored andcommitted
fix(JsonPipe): marks json pipe as not pure Marked json pipe as not pure so that it runs all the time, reflecting changes on the object.
Closes #4821
1 parent e1337dc commit fc016b5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/angular2/src/core/pipes/json_pipe.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import {Pipe} from 'angular2/src/core/metadata';
55

66
/**
77
* Implements json transforms to any object.
8+
* The json pipe runs all the time checking for changes on the transformed object.
89
*
910
* ### Example
1011
*
@@ -25,7 +26,7 @@ import {Pipe} from 'angular2/src/core/metadata';
2526
* ```
2627
*/
2728
@CONST()
28-
@Pipe({name: 'json'})
29+
@Pipe({name: 'json', pure: false})
2930
@Injectable()
3031
export class JsonPipe implements PipeTransform {
3132
transform(value: any, args: any[] = null): string { return Json.stringify(value); }

0 commit comments

Comments
 (0)
X Tutup