mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
fixed ramda imports to reduce bundle size
This commit is contained in:
parent
a497912049
commit
097b091abd
47 changed files with 208 additions and 91 deletions
|
@ -1,6 +1,5 @@
|
|||
import { useCallback, useMemo } from 'react';
|
||||
|
||||
import { flatten, last, uniqBy } from 'ramda';
|
||||
import useSWRInfinite, { SWRInfiniteKeyLoader } from 'swr/infinite';
|
||||
|
||||
import { getLabNodes } from '~/api/lab';
|
||||
|
@ -8,6 +7,7 @@ import { useAuth } from '~/hooks/auth/useAuth';
|
|||
import { useLabStore } from '~/store/lab/useLabStore';
|
||||
import { INode } from '~/types';
|
||||
import { GetLabNodesRequest, ILabNode } from '~/types/lab';
|
||||
import { flatten, last, uniqBy } from '~/utils/ramda';
|
||||
|
||||
const getKey: (isUser: boolean) => SWRInfiniteKeyLoader = isUser => (index, prev: ILabNode[]) => {
|
||||
if (!isUser) return null;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue