Skip to content

Commit

Permalink
Re-fix why-did-you-render
Browse files Browse the repository at this point in the history
  • Loading branch information
martpie committed Dec 4, 2024
1 parent ab90550 commit f7cc445
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/lib/wdyr.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
import React from 'react';

if (process.env.NODE_ENV === 'development') {
const whyDidYouRender = require('@welldone-software/why-did-you-render');
const { default: whyDidYouRender } = await import(
'@welldone-software/why-did-you-render'
);

whyDidYouRender(React, {
trackAllPureComponents: true,
trackHooks: true,
Expand Down

0 comments on commit f7cc445

Please sign in to comment.