diff --git a/README.md b/README.md index 3bcac9ff..3352b70f 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ render previous and current page component when route change. This router loads [history](https://github.com/ReactTraining/history) , [path-to-regexp](https://github.com/pillarjs/path-to-regexp) -and [@wbe/debug](https://github.com/willybrauner/debug) as dependencies. +and [@cher-ami/debug](https://github.com/willybrauner/debug) as dependencies. ## Playground diff --git a/examples/example-client/src/helper/transitionsHelper.ts b/examples/example-client/src/helper/transitionsHelper.ts index 4d9d8fae..0001a85e 100644 --- a/examples/example-client/src/helper/transitionsHelper.ts +++ b/examples/example-client/src/helper/transitionsHelper.ts @@ -1,5 +1,5 @@ import { gsap } from "gsap" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const log = debug(`router:transitionsHelper`) export const transitionsHelper = ( diff --git a/examples/example-client/src/pages/ArticlePage.tsx b/examples/example-client/src/pages/ArticlePage.tsx index 3ec3a875..88ae4b6c 100644 --- a/examples/example-client/src/pages/ArticlePage.tsx +++ b/examples/example-client/src/pages/ArticlePage.tsx @@ -2,7 +2,7 @@ import React, { ForwardedRef, forwardRef, useEffect, useRef } from "react" import { useLocation } from "@cher-ami/router" import { useStack } from "@cher-ami/router" import { transitionsHelper } from "../helper/transitionsHelper" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" interface IProps { params?: { diff --git a/examples/example-client/src/pages/BarPage.tsx b/examples/example-client/src/pages/BarPage.tsx index 08e542ca..19cf27d2 100644 --- a/examples/example-client/src/pages/BarPage.tsx +++ b/examples/example-client/src/pages/BarPage.tsx @@ -11,7 +11,7 @@ import { } from "@cher-ami/router" import { transitionsHelper } from "../helper/transitionsHelper" import { routesList } from "../routes" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const componentName: string = "BarPage" const log = debug(`router:${componentName}`) diff --git a/examples/example-client/src/pages/HomePage.tsx b/examples/example-client/src/pages/HomePage.tsx index 680020d4..3c7b5236 100644 --- a/examples/example-client/src/pages/HomePage.tsx +++ b/examples/example-client/src/pages/HomePage.tsx @@ -10,7 +10,7 @@ import { useStack, } from "@cher-ami/router" import { transitionsHelper } from "../helper/transitionsHelper" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const componentName: string = "HomePage" const log = debug(`router:${componentName}`) diff --git a/examples/example-ssr/package.json b/examples/example-ssr/package.json index 3d083187..3b6d1938 100644 --- a/examples/example-ssr/package.json +++ b/examples/example-ssr/package.json @@ -23,8 +23,8 @@ "@types/react": "^18.2.24", "@types/react-dom": "^18.2.8", "@vitejs/plugin-react": "^4.1.0", - "@wbe/debug": "^1.2.0", - "@wbe/mfs": "^0.1.1", + "@cher-ami/debug": "^1.2.0", + "@cher-ami/mfs": "^0.1.1", "chalk": "^5.3.0", "compression": "^1.7.4", "isomorphic-unfetch": "^4.0.2", diff --git a/examples/example-ssr/prerender/prerender.ts b/examples/example-ssr/prerender/prerender.ts index a9138233..b245abf7 100644 --- a/examples/example-ssr/prerender/prerender.ts +++ b/examples/example-ssr/prerender/prerender.ts @@ -1,6 +1,6 @@ // @ts-ignore import { render } from "~/server/index-server" -import * as mfs from "@wbe/mfs" +import * as mfs from "@cher-ami/mfs" import path, { resolve } from "path" import chalk from "chalk" import { loadEnv } from "vite" diff --git a/examples/example-ssr/src/helpers/transitionsHelper.ts b/examples/example-ssr/src/helpers/transitionsHelper.ts index 4d9d8fae..0001a85e 100644 --- a/examples/example-ssr/src/helpers/transitionsHelper.ts +++ b/examples/example-ssr/src/helpers/transitionsHelper.ts @@ -1,5 +1,5 @@ import { gsap } from "gsap" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const log = debug(`router:transitionsHelper`) export const transitionsHelper = ( diff --git a/examples/example-ssr/src/pages/AboutPage.tsx b/examples/example-ssr/src/pages/AboutPage.tsx index ddc09e57..ad86f691 100644 --- a/examples/example-ssr/src/pages/AboutPage.tsx +++ b/examples/example-ssr/src/pages/AboutPage.tsx @@ -10,7 +10,7 @@ import { } from "@cher-ami/router" import { transitionsHelper } from "../helpers/transitionsHelper" import { getPathByRouteName } from "@cher-ami/router" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import { useLang } from "@cher-ami/router" import { EPages } from "../routes" diff --git a/examples/example-ssr/vite.config.ts b/examples/example-ssr/vite.config.ts index ba93bcf1..07374bbf 100644 --- a/examples/example-ssr/vite.config.ts +++ b/examples/example-ssr/vite.config.ts @@ -1,6 +1,6 @@ import { resolve } from "path" import { defineConfig } from "vite" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import react from "@vitejs/plugin-react" const log = debug("config:vite.config") diff --git a/examples/example-ssr/vite.scripts.config.ts b/examples/example-ssr/vite.scripts.config.ts index 6e2a6c4a..a6e4879f 100644 --- a/examples/example-ssr/vite.scripts.config.ts +++ b/examples/example-ssr/vite.scripts.config.ts @@ -1,6 +1,6 @@ import { resolve } from "path" import { defineConfig } from "vite" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const log = debug("config:vite.config") export default defineConfig(({ command, mode }) => { diff --git a/package.json b/package.json index b8b16e51..b8aa4880 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ } ], "dependencies": { - "@wbe/debug": "^1.2.0", + "@cher-ami/debug": "^1.2.0", "history": "^5.3.0", "path-to-regexp": "^6.2.1", "react": ">=16.8.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index cfe56b55..5a11a3ba 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -4,7 +4,7 @@ importers: .: dependencies: - '@wbe/debug': + '@cher-ami/debug': specifier: ^1.2.0 version: 1.2.0 history: @@ -130,10 +130,10 @@ importers: '@vitejs/plugin-react': specifier: ^4.1.0 version: 4.1.0(vite@4.5.0) - '@wbe/debug': + '@cher-ami/debug': specifier: ^1.2.0 version: 1.2.0 - '@wbe/mfs': + '@cher-ami/mfs': specifier: ^0.1.1 version: 0.1.1 chalk: @@ -869,10 +869,10 @@ packages: pretty-format: 29.7.0 dev: true - /@wbe/debug@1.2.0: + /@cher-ami/debug@1.2.0: resolution: {integrity: sha512-jTCR1JagaS4TpoPR5sjdVfu67Muz5mDB49seMVsbRvetodgPjATELXQWtKRlyrj3hCyZt+rjw1iacYfpCc9Yuw==} - /@wbe/mfs@0.1.1: + /@cher-ami/mfs@0.1.1: resolution: {integrity: sha512-iyvuF6mreeCE2KAiJwmnARCptauaEH98EfGSmPM/A47PrIWg3ZW7MEGP+Adv1ziR9FJb90bnAgr/I9C6Nk8VlA==} dependencies: fs-extra: 10.1.0 diff --git a/src/components/Link.tsx b/src/components/Link.tsx index f7e330ce..b7bd9b60 100644 --- a/src/components/Link.tsx +++ b/src/components/Link.tsx @@ -9,7 +9,7 @@ import { createUrl, TOpenRouteParams } from "../core/core" import { joinPaths, removeLastCharFromString } from "../core/helpers" import { useRouter } from "../hooks/useRouter" import { useLocation } from "../hooks/useLocation" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" // exclude href because it collides with "to" type TAnchorWithoutHref = Omit, "href"> diff --git a/src/components/Router.tsx b/src/components/Router.tsx index bcb9a6c8..07b98ed7 100644 --- a/src/components/Router.tsx +++ b/src/components/Router.tsx @@ -1,4 +1,4 @@ -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import { BrowserHistory, HashHistory, MemoryHistory } from "history" import { Match } from "path-to-regexp" import React, { diff --git a/src/components/Stack.tsx b/src/components/Stack.tsx index 0173704c..05d62926 100644 --- a/src/components/Stack.tsx +++ b/src/components/Stack.tsx @@ -1,6 +1,6 @@ import React from "react" import { IRouterContext } from "./Router" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import { IRouteStack } from "../hooks/useStack" import { useRouter } from "../hooks/useRouter" import { isSSR } from "../core/helpers" diff --git a/src/core/LangService.ts b/src/core/LangService.ts index 4f846c7f..c57638fc 100644 --- a/src/core/LangService.ts +++ b/src/core/LangService.ts @@ -2,7 +2,7 @@ import { Routers } from "./Routers" import { compileUrl, createUrl } from "./core" import { isSSR, joinPaths, removeLastCharFromString } from "./helpers" import { TRoute } from "../components/Router" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const log = debug(`router:LangService`) diff --git a/src/core/core.ts b/src/core/core.ts index 7b01893c..33b1f1f1 100644 --- a/src/core/core.ts +++ b/src/core/core.ts @@ -1,5 +1,5 @@ import { Routers } from "./Routers" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import { compile, match } from "path-to-regexp" import { TRoute } from "../components/Router" import LangService from "./LangService" diff --git a/src/core/staticPropsCache.ts b/src/core/staticPropsCache.ts index a2557574..94d644e5 100644 --- a/src/core/staticPropsCache.ts +++ b/src/core/staticPropsCache.ts @@ -1,5 +1,5 @@ import { Routers } from "./Routers" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const componentName: string = "cache" const log = debug(`router:${componentName}`) diff --git a/src/hooks/useHistory.ts b/src/hooks/useHistory.ts index 62301dc6..a8113fdc 100644 --- a/src/hooks/useHistory.ts +++ b/src/hooks/useHistory.ts @@ -1,7 +1,7 @@ import { BrowserHistory, HashHistory, MemoryHistory, Update } from "history" import React from "react" import { useRouter } from "./useRouter" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" const log = debug("router:useHistory") diff --git a/src/hooks/useLang.ts b/src/hooks/useLang.ts index 23d6a04c..4d74ff82 100644 --- a/src/hooks/useLang.ts +++ b/src/hooks/useLang.ts @@ -1,5 +1,5 @@ import LangService, { TLanguage } from "../core/LangService" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import React from "react" import { Routers } from "../core/Routers" import { useHistory } from "../hooks/useHistory" diff --git a/src/hooks/useLocation.ts b/src/hooks/useLocation.ts index ad970288..a2365e4e 100644 --- a/src/hooks/useLocation.ts +++ b/src/hooks/useLocation.ts @@ -1,7 +1,7 @@ import { useState } from "react" import { useHistory } from "../hooks/useHistory" import { createUrl, TOpenRouteParams } from "../core/core" -import debug from "@wbe/debug" +import debug from "@cher-ami/debug" import { useRouter } from "./useRouter" const log = debug("router:useLocation") diff --git a/tsup.config.ts b/tsup.config.ts index f1c52535..47e07fe1 100644 --- a/tsup.config.ts +++ b/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ dts: true, format: ["cjs", "esm"], name: "@cher-ami/router", - external: ["@wbe/debug", "history", "path-to-regexp", "react", "react-dom"], + external: ["@cher-ami/debug", "history", "path-to-regexp", "react", "react-dom"], sourcemap: true, async onSuccess() { const process = spawn("npx", ["size-limit"], { shell: true })