-
-
Save tarlepp/842007db8c73241f1bb9f49f5a11d13e to your computer and use it in GitHub Desktop.
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
private partitionArray(array: Array<any>, size: number) { | |
return array.map((e, i) => (i % size === 0) ? array.slice(i, i + size) : null).filter((e) => e); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment