Created
March 17, 2020 01:34
-
-
Save bpinedah/7f3dc7f5b51456b4f5aec2726611490e to your computer and use it in GitHub Desktop.
Routes article
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @description Get a flat array | |
* @param arr Array to flat | |
* @private | |
*/ | |
const _toFlat = arr => [].concat(...arr); | |
const functions = routesFound.map(i => ([...i.middlewares])); | |
const fns = _toFlat(functions); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment