@lifi/widget
Version:
LI.FI Widget for cross-chain bridging and swapping. It will drive your multi-chain strategy and attract new users from everywhere.
11 lines • 430 B
JavaScript
import { useContext } from 'react';
import { useShallow } from 'zustand/shallow';
import { FormStoreContext } from './FormStoreContext.js';
export function useFormStore(selector) {
const useStore = useContext(FormStoreContext);
if (!useStore) {
throw new Error('You forgot to wrap your component in <FormStoreProvider>.');
}
return useStore(useShallow(selector));
}
//# sourceMappingURL=useFormStore.js.map