xenial-black
xenial-black17mo ago

when i build my nextjs project. I get this error `import { useLogin, useTranslate } from "@hooks`

the nextjs project is built from official tool.
5 Replies
kapa.ai
kapa.ai17mo ago
Hi @joegor. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- To integrate refine with a Next.js project, you can use the @refinedev/nextjs-router package. This package provides easy integration between refine and Next.js for both existing projects and new projects without giving up the benefits of Next.js. To install the package, run:
npm i @refinedev/nextjs-router
npm i @refinedev/nextjs-router
For initializing a new refine project with Next.js, you can use the create refine-app command:
npm create refine-app@latest -- -o refine-nextjs my-refine-nextjs-app
npm create refine-app@latest -- -o refine-nextjs my-refine-nextjs-app
For more information, refer to the refine Next.js documentation (https://refine.dev/docs/packages/documentation/routers/nextjs/). ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai17mo ago
<@666988497940250624> kapa.ai is still learning and improving, please let us how it did by reacting below
xenial-black
xenial-black17mo ago
No description
Omer
Omer17mo ago
Hey @joegor , we're sorry about this issue. Could you please share the options you selected when creating the project so that we can replicate the error?
xenial-black
xenial-black17mo ago
i just fixed it thanks. I review all my import path related to refine. My IDE auto import the path inside src and causing the issue this line import { CrudFilter } from "@refinedev/core/src/contexts/data/IDataContext" i change it to import { CrudFilter } from "@refinedev/core" thanks