What is pipe() function in Angular

前端 未结 5 1591
时光取名叫无心
时光取名叫无心 2020-12-12 13:10

Pipes are filters for transforming data (formats) in the template.

I came across the pipe() function as below. What does this pipe() functi

5条回答
  •  忘掉有多难
    2020-12-12 14:02

    RxJS Operators are functions that build on the observables foundation to enable sophisticated manipulation of collections.

    For example, RxJS defines operators such as map(), filter(), concat(), and flatMap().

    You can use pipes to link operators together. Pipes let you combine multiple functions into a single function.

    The pipe() function takes as its arguments the functions you want to combine, and returns a new function that, when executed, runs the composed functions in sequence.

提交回复
热议问题