From 94b160c9cdee41ec8327d1616d417d3f8296dc71 Mon Sep 17 00:00:00 2001 From: David Arranz Date: Mon, 9 Sep 2024 16:51:14 +0200 Subject: [PATCH] . --- client/src/App.tsx | 8 ++------ client/src/main.tsx | 3 --- client/src/wdyr.ts | 13 ------------- 3 files changed, 2 insertions(+), 22 deletions(-) delete mode 100644 client/src/wdyr.ts diff --git a/client/src/App.tsx b/client/src/App.tsx index f66ac4d..096ad99 100644 --- a/client/src/App.tsx +++ b/client/src/App.tsx @@ -21,12 +21,8 @@ function App() { return ( - - + + diff --git a/client/src/main.tsx b/client/src/main.tsx index d1aeef9..be3ddaa 100644 --- a/client/src/main.tsx +++ b/client/src/main.tsx @@ -1,6 +1,3 @@ -// eslint-disable-next-line import/order -import "./wdyr"; // <--- always first import - import React from "react"; import ReactDOM from "react-dom/client"; import App from "./App.tsx"; diff --git a/client/src/wdyr.ts b/client/src/wdyr.ts deleted file mode 100644 index cc3420f..0000000 --- a/client/src/wdyr.ts +++ /dev/null @@ -1,13 +0,0 @@ -/// -import * as React from "react"; - -if (import.meta.env.DEV && import.meta.env.VITE_ENABLE_WHY_DID_YOU_RENDER === "true") { - const { default: wdyr } = await import("@welldone-software/why-did-you-render"); - - wdyr(React, { - include: [/.*/], - exclude: [/^BrowserRouter/, /^Link/, /^Route/], - trackHooks: true, - trackAllPureComponents: true, - }); -}