Skip to content

Commit

Permalink
perf: memo Activity
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <[email protected]>
  • Loading branch information
Innei committed Jul 9, 2023
1 parent 2f0fffe commit cc0cc47
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/layout/header/internal/Activity.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ const appLabels: { [app: string]: string } = {
cmusic: 'cmusic',
}
// autocorrect: true
export function Activity() {
export const Activity = memo(() => {
const [isEnabled, setIsEnabled] = useState(true)

const activity = useActivity()
Expand Down Expand Up @@ -161,7 +161,8 @@ export function Activity() {
</AnimatePresence>
</>
)
}
})
Activity.displayName = 'Activity'
const cMusicProps = { processName: 'cmusic' }
const TriggerComponent = memo<{
processName: string
Expand Down

1 comment on commit cc0cc47

@vercel
Copy link

@vercel vercel bot commented on cc0cc47 Jul 9, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

shiro – ./

shiro-git-main-innei.vercel.app
shiro-innei.vercel.app
springtide.vercel.app
innei.in

Please sign in to comment.