File tree 1 file changed +19
-0
lines changed
1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 3
3
## 1.0.2
4
4
* [[ #50 ] ( https://github.com/VadimDez/ngx-filter-pipe/issues/50 )] - How to call filterPipe transform from Component ?
5
5
6
+ ### Use FilterPipe in a component
7
+
8
+ Inject ` FilterPipe ` into your component and use it:
9
+
10
+ ``` ts
11
+ class AppComponent {
12
+ objects = [
13
+ { name: ' John' },
14
+ { name: ' Nick' },
15
+ { name: ' Jane' }
16
+ ];
17
+
18
+ constructor (private filter : FilterPipe ) {
19
+ let result = this .filter .transform (this .objects , { name: ' J' });
20
+ console .log (result ); // [{ name: 'John' }, { name: 'Jane' }]
21
+ }
22
+ }
23
+ ```
24
+
6
25
## 1.0.1
7
26
* [[ #46 ] ( https://github.com/VadimDez/ngx-filter-pipe/issues/46 )] - Filter by property/method on prototype chain.
8
27
* [[ #47 ] ( https://github.com/VadimDez/ngx-filter-pipe/pull/47 )] - walk the prototype chain to check if field/property exists.
You can’t perform that action at this time.
0 commit comments