Skip to content

Commit

Permalink
took chunk function from lodash
Browse files Browse the repository at this point in the history
  • Loading branch information
matthew44-mappable committed Apr 18, 2024
1 parent ea32f74 commit 4713289
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 12 deletions.
4 changes: 2 additions & 2 deletions tools/icons/fetch-icons.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {Api as FigmaApi, isNodeType, Node} from 'figma-api';
import {GetImageResult} from 'figma-api/lib/api-types';
import {makeChunks} from '../utils/make-chunks';
import lodashChunk from 'lodash/chunk';

export type IconDescription = {
componentId: string;
Expand Down Expand Up @@ -115,7 +115,7 @@ const getImageLinks = async (
fileId: string,
api: FigmaApi
): Promise<IconDescriptionWithLink[]> => {
const chunks = makeChunks(descriptions, ICONS_PER_CHUNK);
const chunks = lodashChunk(descriptions, ICONS_PER_CHUNK);
const linkChunks = await Promise.all(
chunks.map((chunk) =>
api.getImage(fileId, {
Expand Down
10 changes: 0 additions & 10 deletions tools/utils/make-chunks.ts

This file was deleted.

0 comments on commit 4713289

Please sign in to comment.