Skip to content

Commit

Permalink
Fix flickering
Browse files Browse the repository at this point in the history
  • Loading branch information
joel-jeremy committed Sep 18, 2024
1 parent ed38f61 commit 01e41fa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/desktop-client/src/components/accounts/Account.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import React, {
createRef,
useMemo,
type ReactElement,
useEffect,
useLayoutEffect,
} from 'react';
import { Trans } from 'react-i18next';
import { useSelector } from 'react-redux';
Expand Down Expand Up @@ -160,7 +160,7 @@ function AllTransactions({
const prependTransactions: PreviewTransactionEntity[] =
usePreviewTransactions({ accountId });

useEffect(() => {
useLayoutEffect(() => {
splitsExpandedDispatch({
type: 'close-splits',
ids: prependTransactions.filter(t => t.is_parent).map(t => t.id),
Expand Down

0 comments on commit 01e41fa

Please sign in to comment.