Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect path in types #109

Open
patik opened this issue Oct 11, 2023 · 0 comments
Open

Incorrect path in types #109

patik opened this issue Oct 11, 2023 · 0 comments

Comments

@patik
Copy link

patik commented Oct 11, 2023

I had to create a patch for this type definition that tries to import from Next

diff --git a/node_modules/next-router-mock/dist/MemoryRouterProvider/MemoryRouterProvider.d.ts b/node_modules/next-router-mock/dist/MemoryRouterProvider/MemoryRouterProvider.d.ts
index 0318cb2..7d751b1 100644
--- a/node_modules/next-router-mock/dist/MemoryRouterProvider/MemoryRouterProvider.d.ts
+++ b/node_modules/next-router-mock/dist/MemoryRouterProvider/MemoryRouterProvider.d.ts
@@ -1,7 +1,7 @@
 import React, { ReactNode } from "react";
 import { Url } from "../index";
 import { MemoryRouterEventHandlers } from "../useMemoryRouter";
-type AbstractedNextDependencies = Pick<typeof import("next/dist/shared/lib/router-context.shared-runtime"), "RouterContext">;
+type AbstractedNextDependencies = Pick<typeof import("next/dist/shared/lib/router-context.js"), "RouterContext">;
 export type MemoryRouterProviderProps = {
     /**
      * The initial URL to render.
      *

I'm running Next 13.3.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant