package.dist.infinite.react-server.mjs Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of swr Show documentation
Show all versions of swr Show documentation
React Hooks library for remote data fetching
The newest version!
import { INFINITE_PREFIX, serialize } from 'swr/_internal';
const getFirstPageKey = (getKey)=>{
return serialize(getKey ? getKey(0, null) : null)[0];
};
const unstable_serialize = (getKey)=>{
return INFINITE_PREFIX + getFirstPageKey(getKey);
};
export { unstable_serialize };