mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
feat: improve library preview image generation on publish (#4321)
Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>
This commit is contained in:
parent
ca1f3aa094
commit
b53d1f6f3e
8 changed files with 157 additions and 72 deletions
|
@ -151,7 +151,10 @@ export const debounce = <T extends any[]>(
|
|||
};
|
||||
|
||||
// https://github.com/lodash/lodash/blob/es/chunk.js
|
||||
export const chunk = <T extends any>(array: T[], size: number): T[][] => {
|
||||
export const chunk = <T extends any>(
|
||||
array: readonly T[],
|
||||
size: number,
|
||||
): T[][] => {
|
||||
if (!array.length || size < 1) {
|
||||
return [];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue