VOOZH about

URL: https://www.geeksforgeeks.org/javascript/underscore-js-_-compose-function/

⇱ Underscore.js _.compose() Function - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Underscore.js _.compose() Function

Last Updated : 25 Nov, 2021
The _.compose() function is used to return the composition of the list of functions. The list of the function returns the value of the function that follows. Syntax:
_.compose(*functions)
Parameters: This function accept a single parameter as mentioned above and described below:
  • functions: It contains the list of function that to be executed.
Return Value: It returns the composition of list of functions. Below examples illustrate the _.compose() function in Underscore.js: Example 1: Output: 👁 Image
Example 2:
Output: 👁 Image
Comment