Skip to content

Commit

Permalink
dont memoize countdown
Browse files Browse the repository at this point in the history
  • Loading branch information
vinceau committed Feb 14, 2024
1 parent b06705d commit ac50dd3
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/renderer/pages/home/sidebar/slippi_store.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,7 @@ const styles = stylex.create({
},
});

const InternalSlippiStore = React.memo(function InternalSlippiStore({
shopOpen,
countdown,
}: {
shopOpen: boolean;
countdown: string;
}) {
const InternalSlippiStore = ({ shopOpen, countdown }: { shopOpen: boolean; countdown: string }) => {
const buttonText = shopOpen ? "Click to Shop" : "Shop closed";
return (
<div {...stylex.props(styles.container)}>
Expand Down Expand Up @@ -72,7 +66,7 @@ const InternalSlippiStore = React.memo(function InternalSlippiStore({
)}
</div>
);
});
};

export const SlippiStore = React.memo(function SlippiStore() {
const [shopOpen, setShopOpen] = React.useState(true);
Expand Down

0 comments on commit ac50dd3

Please sign in to comment.