|
1 | | -import Settings from "@/Components/Settings"; |
| 1 | +import Settings from "@/components/Settings"; |
2 | 2 | import { tools } from "@/constants/tools"; |
3 | 3 | import loadable from "@loadable/component"; |
4 | 4 | import React from "react"; |
5 | 5 | import { Navigate, Route, Routes } from "react-router-dom"; |
6 | 6 | import ErrorBoundary from "./ErrorBoundary"; |
7 | 7 |
|
8 | 8 | const componentMap = { |
9 | | - jwt: loadable(() => import("../Features/jwt/JWT")) as React.ComponentType, |
10 | | - escape: loadable(() => import("../Features/escape/BackslashEscape")) as React.ComponentType, |
11 | | - markdown: loadable(() => import("../Features/markdown/Markdown")) as React.ComponentType, |
12 | | - "har-viewer": loadable(() => import("../Features/har/HarViewer")) as React.ComponentType, |
13 | | - "ssh-keys": loadable(() => import("../Features/ssh/SSH")) as React.ComponentType, |
14 | | - "svg-preview": loadable(() => import("../Features/svg/Svg")) as React.ComponentType, |
15 | | - ids: loadable(() => import("../Features/ids/Ids")) as React.ComponentType, |
16 | | - cron: loadable(() => import("../Features/cron/Cron")) as React.ComponentType, |
17 | | - bundlephobia: loadable( |
18 | | - () => import("../Features/bundlephobia/Bundlephobia") |
19 | | - ) as React.ComponentType, |
20 | | - regex: loadable(() => import("../Features/regex/RegexAdvanced")) as React.ComponentType, |
21 | | - rest: loadable(() => import("../Features/rest/Rest")) as React.ComponentType, |
22 | | - graphiql: loadable(() => import("../Features/graphiql/GraphiQL")) as React.ComponentType, |
23 | | - epoch: loadable(() => import("../Features/epoch/Epoch")) as React.ComponentType, |
24 | | - dns: loadable(() => import("../Features/dns/DnsLookup")) as React.ComponentType, |
25 | | - hmac: loadable(() => import("../Features/hmac/HmacGenerator")) as React.ComponentType, |
26 | | - "url-parser": loadable(() => import("@/Features/url/UrlParser")) as React.ComponentType, |
27 | | - "url-encoder": loadable(() => import("@/Features/url/UrlEncoder")) as React.ComponentType, |
28 | | - "certificate-decoder": loadable(() => import("../Features/x509/X509")) as React.ComponentType, |
29 | | - "json-formatter": loadable(() => import("../Features/json/JsonFormatter")) as React.ComponentType, |
30 | | - timezone: loadable(() => import("@/Features/timezone/Timezone")) as React.ComponentType, |
31 | | - dashboard: loadable(() => import("@/Features/dashboard/Dashboard")) as React.ComponentType, |
| 9 | + jwt: loadable(() => import("../pages/jwt/JWT")) as React.ComponentType, |
| 10 | + escape: loadable(() => import("../pages/escape/BackslashEscape")) as React.ComponentType, |
| 11 | + markdown: loadable(() => import("../pages/markdown/Markdown")) as React.ComponentType, |
| 12 | + "har-viewer": loadable(() => import("../pages/har/HarViewer")) as React.ComponentType, |
| 13 | + "ssh-keys": loadable(() => import("../pages/ssh/SSH")) as React.ComponentType, |
| 14 | + "svg-preview": loadable(() => import("../pages/svg/Svg")) as React.ComponentType, |
| 15 | + ids: loadable(() => import("../pages/ids/Ids")) as React.ComponentType, |
| 16 | + cron: loadable(() => import("../pages/cron/Cron")) as React.ComponentType, |
| 17 | + bundlephobia: loadable(() => import("../pages/bundlephobia/Bundlephobia")) as React.ComponentType, |
| 18 | + regex: loadable(() => import("../pages/regex/RegexAdvanced")) as React.ComponentType, |
| 19 | + rest: loadable(() => import("../pages/rest/Rest")) as React.ComponentType, |
| 20 | + graphiql: loadable(() => import("../pages/graphiql/GraphiQL")) as React.ComponentType, |
| 21 | + epoch: loadable(() => import("../pages/epoch/Epoch")) as React.ComponentType, |
| 22 | + dns: loadable(() => import("../pages/dns/DnsLookup")) as React.ComponentType, |
| 23 | + hmac: loadable(() => import("../pages/hmac/HmacGenerator")) as React.ComponentType, |
| 24 | + "url-parser": loadable(() => import("@/pages/url/UrlParser")) as React.ComponentType, |
| 25 | + "url-encoder": loadable(() => import("@/pages/url/UrlEncoder")) as React.ComponentType, |
| 26 | + "certificate-decoder": loadable(() => import("../pages/x509/X509")) as React.ComponentType, |
| 27 | + "json-formatter": loadable(() => import("../pages/json/JsonFormatter")) as React.ComponentType, |
| 28 | + timezone: loadable(() => import("@/pages/timezone/Timezone")) as React.ComponentType, |
| 29 | + dashboard: loadable(() => import("@/pages/dashboard/Dashboard")) as React.ComponentType, |
32 | 30 | }; |
33 | 31 | // Dynamically create lazy-loaded components |
34 | 32 | const routes = tools |
|
0 commit comments