Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const group = ( list, [ first, ...rest ] ) =>
- rest.reduce(
- ( grouped, key ) =>
- grouped.map( group =>
- _.partition( group, key )
- ),
- _.partition( list, first )
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement