Skip to content

Commit

Permalink
refactor: use state selectors instead of destructuring for rerender p…
Browse files Browse the repository at this point in the history
…erformance
  • Loading branch information
Alunara committed Jan 10, 2025
1 parent c7ad441 commit 8b11c1a
Show file tree
Hide file tree
Showing 70 changed files with 100 additions and 110 deletions.
2 changes: 1 addition & 1 deletion apps/dao/src/components/ConnectWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ type ConnectWalletProps = {
const ConnectWallet: React.FC<ConnectWalletProps> = ({ description, connectText, loadingText }) => {
const updateConnectWalletStateKeys = useStore((state) => state.wallet.updateConnectWalletStateKeys)
const connectState = useStore((state) => state.connectState)
const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

const loading = isLoading(connectState)

Expand Down
2 changes: 1 addition & 1 deletion apps/dao/src/hooks/usePageOnMount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function usePageOnMount(params: Params, location: Location, navigate: NavigateFu
const updateCurveJs = useStore((state) => state.updateCurveJs)
const updateGlobalStoreByKey = useStore((state) => state.updateGlobalStoreByKey)

const { setLocale } = useUserProfileStore()
const setLocale = useUserProfileStore((state) => state.setLocale)

const walletChainId = getWalletChainId(wallet)
const walletSignerAddress = getWalletSignerAddress(wallet)
Expand Down
4 changes: 3 additions & 1 deletion apps/dao/src/layout/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ export const Header = ({ sections, BannerProps }: HeaderProps) => {
const routerProps = useStore((state) => state.routerProps)
const updateConnectState = useStore((state) => state.updateConnectState)

const { locale, theme, setTheme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const setTheme = useUserProfileStore((state) => state.setTheme)
const locale = useUserProfileStore((state) => state.locale)

const location = useLocation()
const { rLocalePathname } = getLocaleFromUrl()
Expand Down
2 changes: 1 addition & 1 deletion apps/dao/src/layout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const BaseLayout = ({ children }: { children: React.ReactNode }) => {
const updateConnectState = useStore((state) => state.updateConnectState)
const updateLayoutHeight = useStore((state) => state.updateLayoutHeight)

const { locale } = useUserProfileStore()
const locale = useUserProfileStore((state) => state.locale)

useEffect(() => {
updateLayoutHeight('globalAlert', globalAlertHeight)
Expand Down
4 changes: 3 additions & 1 deletion apps/dao/src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ function CurveApp({ Component }: AppProps) {
const onboard = useStore((state) => state.wallet.onboard)
const isPageVisible = useStore((state) => state.isPageVisible)

const { locale, setLocale, theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const locale = useUserProfileStore((state) => state.locale)
const setLocale = useUserProfileStore((state) => state.setLocale)

const [appLoaded, setAppLoaded] = useState(false)

Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/AdvancedSettings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export const AdvancedSettings = ({ className, buttonIcon, maxSlippage }: React.P
const overlayTriggerState = useOverlayTriggerState({})
const isMobile = useStore((state) => state.isMobile)

const { setMaxSlippage } = useUserProfileStore()
const setMaxSlippage = useUserProfileStore((state) => state.setMaxSlippage)

const [formValues, setFormValues] = useState(DEFAULT_FORM_VALUES)

Expand Down
3 changes: 2 additions & 1 deletion apps/lend/src/components/ChartOhlcWrapper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ const ChartOhlcWrapper: React.FC<ChartOhlcWrapperProps> = ({ rChainId, userActiv
(state) => state.loanCollateralRemove.detailInfo[loanCollateralRemoveActiveKey]?.prices ?? null,
)

const { isAdvancedMode, theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const isMdUp = useStore((state) => state.layout.isMdUp)
const {
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/ConnectWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const ConnectWallet: React.FC<ConnectWalletProps> = ({ description, connectText,
const connectState = useStore((state) => state.connectState)
const loading = isLoading(connectState)

const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

return (
<ConnectWalletPrompt
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/DetailInfoLeverageX.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const DetailInfoLeverageX = ({
maxLeverage: string | undefined
loading: boolean
}) => {
const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

return (
<DetailInfo label={t`Leverage:`} loading={loading} loadingSkeleton={[50, 20]}>
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/DetailInfoLiqRange.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const DetailInfoLiqRange = ({
const userDetailsResp = useStore((state) => state.user.loansDetailsMapper[userActiveKey])
const loanPricesResp = useStore((state) => state.markets.pricesMapper[rChainId]?.[rOwmId])

const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

const { prices: loanPrices } = loanPricesResp ?? {}
const { prices: currPrices, bands: currBands } = userDetailsResp?.details ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const MarketParameters = ({
const vaultPricePerShareResp = useStore((state) => state.markets.vaultPricePerShare[rChainId]?.[rOwmId])
const fetchVaultPricePerShare = useStore((state) => state.markets.fetchVaultPricePerShare)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { prices, error: pricesError } = loanPricesResp ?? {}
const { parameters, error: parametersError } = parametersResp ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const DetailsUserLoan = (pageProps: PageContentProps) => {
const userLoanDetailsResp = useStore((state) => state.user.loansDetailsMapper[userActiveKey])
const chartExpanded = useStore((state) => state.ohlcCharts.chartExpanded)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

// TODO: handle error
const { details: userLoanDetails } = userLoanDetailsResp ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const DetailsUserLoanChartLiquidationRange = ({ rChainId, rOwmId, userActiveKey
const loanDetailsPrices = useStore((state) => state.markets.pricesMapper[rChainId]?.[rOwmId]?.prices)
const userLoanDetails = useStore((state) => state.user.loansDetailsMapper[userActiveKey]?.details)

const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

const { prices: currPrices, status } = userLoanDetails ?? {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,8 @@ const DetailInfoLeverage = ({
const isEditLiqRange = useStore((state) => state.loanCreate.isEditLiqRange)
const liqRanges = useStore((state) => state.loanCreate.liqRanges[activeKeyLiqRange])

const {
isAdvancedMode,
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const { signerAddress } = api ?? {}
const { minBands, maxBands, borrowed_token, collateral_token } = market ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const DetailInfoNonLeverage = ({
const isEditLiqRange = useStore((state) => state.loanCreate.isEditLiqRange)
const liqRanges = useStore((state) => state.loanCreate.liqRanges[activeKeyLiqRange])

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { signerAddress } = api ?? {}
const { borrowed_token, collateral_token } = market ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,8 @@ const LoanCreate = ({ isLeverage = false, ...pageProps }: PageContentProps & { i
const setFormValues = useStore((state) => state.loanCreate.setFormValues)
const resetState = useStore((state) => state.loanCreate.resetState)

const {
isAdvancedMode,
theme,
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const [{ isConfirming, confirmedWarning }, setConfirmWarning] = useState(DEFAULT_CONFIRM_WARNING)
const [healthMode, setHealthMode] = useState(DEFAULT_HEALTH_MODE)
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/PageLoanCreate/Page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ const Page: NextPage = () => {
const { chartExpanded, setChartExpanded } = useStore((state) => state.ohlcCharts)
const provider = useStore((state) => state.wallet.getProvider(''))

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const [isLoaded, setLoaded] = useState(false)
const [initialLoaded, setInitialLoaded] = useState(false)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const DetailInfo = ({
const formEstGas = useStore((state) => state.loanBorrowMore.formEstGas[activeKey])
const formValues = useStore((state) => state.loanBorrowMore.formValues)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { signerAddress } = api ?? {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@ const DetailInfoLeverage = ({
const formEstGas = useStore((state) => state.loanBorrowMore.formEstGas[activeKey])
const formValues = useStore((state) => state.loanBorrowMore.formValues)

const {
isAdvancedMode,
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const { signerAddress } = api ?? {}
const { expectedCollateral, routeImage } = detailInfo ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ const LoanBorrowMore = ({
const setFormValues = useStore((state) => state.loanBorrowMore.setFormValues)
const resetState = useStore((state) => state.loanBorrowMore.resetState)

const {
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const [{ isConfirming, confirmedWarning }, setConfirmWarning] = useState(DEFAULT_CONFIRM_WARNING)
const [healthMode, setHealthMode] = useState(DEFAULT_HEALTH_MODE)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const LoanCollateralAdd = ({ rChainId, rOwmId, api, isLoaded, market, userActive
const setFormValues = useStore((state) => state.loanCollateralAdd.setFormValues)
const resetState = useStore((state) => state.loanCollateralAdd.resetState)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const [healthMode, setHealthMode] = useState(DEFAULT_HEALTH_MODE)
const [steps, setSteps] = useState<Step[]>([])
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const LoanCollateralRemove = ({ rChainId, rOwmId, isLoaded, api, market, userAct
const setFormValues = useStore((state) => state.loanCollateralRemove.setFormValues)
const resetState = useStore((state) => state.loanCollateralRemove.resetState)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const [{ confirmedWarning }, setConfirmWarning] = useState(DEFAULT_CONFIRM_WARNING)
const [healthMode, setHealthMode] = useState(DEFAULT_HEALTH_MODE)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,8 @@ const DetailInfo = ({
const formEstGas = useStore((state) => state.loanRepay.formEstGas[activeKey])
const formValues = useStore((state) => state.loanRepay.formValues)

const {
isAdvancedMode,
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const detailInfo = detailInfoNonLeverage ?? detailInfoLeverage

Expand Down
4 changes: 1 addition & 3 deletions apps/lend/src/components/PageLoanManage/LoanRepay/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,7 @@ const LoanRepay = ({ rChainId, rOwmId, isLoaded, api, market, userActiveKey }: P
const setFormValues = useStore((state) => state.loanRepay.setFormValues)
const resetState = useStore((state) => state.loanRepay.resetState)

const {
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const [{ isConfirming, confirmedWarning }, setConfirmWarning] = useState(DEFAULT_CONFIRM_WARNING)
const [healthMode, setHealthMode] = useState(DEFAULT_HEALTH_MODE)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,7 @@ const LoanSelfLiquidation = ({ rChainId, rOwmId, isLoaded, api, market, userActi
const notifyNotification = useStore((state) => state.wallet.notifyNotification)
const resetState = useStore((state) => state.loanSelfLiquidation.resetState)

const {
maxSlippage: { global: maxSlippage },
} = useUserProfileStore()
const maxSlippage = useUserProfileStore((state) => state.maxSlippage.global)

const [steps, setSteps] = useState<Step[]>([])
const [txInfoBar, setTxInfoBar] = useState<React.ReactNode | null>(null)
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/PageLoanManage/Page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ const Page: NextPage = () => {
const { chartExpanded, setChartExpanded } = useStore((state) => state.ohlcCharts)
const provider = useStore((state) => state.wallet.getProvider(''))

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { signerAddress } = api ?? {}
const { borrowed_token, collateral_token } = market ?? {}
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/PageMarketList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const MarketList = (pageProps: PageMarketList) => {
const setFormValues = useStore((state) => state.marketList.setFormValues)
const { initCampaignRewards, initiated } = useStore((state) => state.campaigns)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { signerAddress } = api ?? {}

Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/components/PageVault/Page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const Page: NextPage = () => {
const setMarketsStateKey = useStore((state) => state.markets.setStateByKey)
const provider = useStore((state) => state.wallet.getProvider(''))

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { signerAddress } = api ?? {}
const { borrowed_token } = market ?? {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const CellTotalCollateralValue = ({ rChainId, rOwmId }: { rChainId: ChainId; rOw
const totalCollateralValue = useStore((state) => state.markets.totalCollateralValuesMapper[rChainId]?.[rOwmId])
const fetchTotalCollateralValue = useStore((state) => state.markets.fetchTotalCollateralValue)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const { total = null, tooltipContent = [], error } = totalCollateralValue ?? {}

Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/hooks/usePageOnMount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function usePageOnMount(params: Params, location: Location, navigate: NavigateFu
const updateProvider = useStore((state) => state.wallet.updateProvider)
const updateGlobalStoreByKey = useStore((state) => state.updateGlobalStoreByKey)

const { setLocale } = useUserProfileStore()
const setLocale = useUserProfileStore((state) => state.setLocale)

const walletChainId = getWalletChainId(wallet)
const walletSignerAddress = getWalletSignerAddress(wallet)
Expand Down
6 changes: 5 additions & 1 deletion apps/lend/src/layout/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ const Header = ({ chainId, sections, BannerProps }: HeaderProps) => {
const isMdUp = useMediaQuery(isMdUpQuery, { noSsr: true })
const { data: tvl } = useTvl(chainId)

const { locale, isAdvancedMode, setAdvancedMode, theme, setTheme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const setTheme = useUserProfileStore((state) => state.setTheme)
const locale = useUserProfileStore((state) => state.locale)
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)
const setAdvancedMode = useUserProfileStore((state) => state.setAdvancedMode)

const location = useLocation()
const { params: routerParams } = routerProps ?? {}
Expand Down
2 changes: 1 addition & 1 deletion apps/lend/src/layout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const BaseLayout = ({ children }: { children: React.ReactNode }) => {
const setLayoutHeight = useStore((state) => state.layout.setLayoutHeight)
const updateConnectState = useStore((state) => state.updateConnectState)

const { locale } = useUserProfileStore()
const locale = useUserProfileStore((state) => state.locale)

const [networkSwitch, setNetworkSwitch] = useState('')

Expand Down
3 changes: 2 additions & 1 deletion apps/lend/src/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ function CurveApp({ Component }: AppProps) {
const updateGlobalStoreByKey = useStore((state) => state.updateGlobalStoreByKey)
const updateWalletStateByKey = useStore((state) => state.wallet.setStateByKey)

const { locale, theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const locale = useUserProfileStore((state) => state.locale)

const [appLoaded, setAppLoaded] = useState(false)

Expand Down
2 changes: 1 addition & 1 deletion apps/loan/src/components/AdvancedSettings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export const AdvancedSettings = ({ className, buttonIcon, maxSlippage }: React.P
const overlayTriggerState = useOverlayTriggerState({})
const isMobile = useStore((state) => state.isMobile)

const { setMaxSlippage } = useUserProfileStore()
const setMaxSlippage = useUserProfileStore((state) => state.setMaxSlippage)

const [formValues, setFormValues] = useState(DEFAULT_FORM_VALUES)

Expand Down
3 changes: 2 additions & 1 deletion apps/loan/src/components/ChartOhlcWrapper/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ const ChartOhlcWrapper: React.FC<ChartOhlcWrapperProps> = ({ rChainId, llamma, l
(state) => state.loanCollateralDecrease.detailInfo[collateralDecreaseActiveKey]?.prices ?? null,
)

const { isAdvancedMode, theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const isMdUp = useStore((state) => state.layout.isMdUp)
const {
Expand Down
2 changes: 1 addition & 1 deletion apps/loan/src/components/ConnectWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const ConnectWallet: React.FC<ConnectWalletProps> = ({ description, connectText,
const connectState = useStore((state) => state.connectState)
const loading = isLoading(connectState)

const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

return (
<ConnectWalletPrompt
Expand Down
2 changes: 1 addition & 1 deletion apps/loan/src/components/DetailInfoLiqRange.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const DetailInfoLiqRange = ({
userLoanDetails: UserLoanDetails | undefined
handleLiqRangesEdit?: () => void
}) => {
const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

const { userPrices: currPrices, userBands: currBands } = userLoanDetails ?? {}

Expand Down
2 changes: 1 addition & 1 deletion apps/loan/src/components/LoanInfoLlamma/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const LoanInfoLlamma = (props: Props) => {
const { rChainId, llamma, llammaId } = props
const chartExpanded = useStore((state) => state.ohlcCharts.chartExpanded)

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

return (
<Wrapper>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const ChartUserLiquidationRange = ({ healthMode, llammaId }: { healthMode: Healt
const loanDetails = useStore((state) => state.loans.detailsMapper[llammaId])
const userLoanDetails = useStore((state) => state.loans.userDetailsMapper[llammaId])

const { theme } = useUserProfileStore()
const theme = useUserProfileStore((state) => state.theme)

const { userPrices: currPrices } = userLoanDetails ?? {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const UserInfos = ({
}) => {
const userLoanDetails = useStore((state) => state.loans.userDetailsMapper[llammaId])

const { isAdvancedMode } = useUserProfileStore()
const isAdvancedMode = useUserProfileStore((state) => state.isAdvancedMode)

const {
coins: [stablecoin],
Expand Down
Loading

0 comments on commit 8b11c1a

Please sign in to comment.