Closed shawqicauses closed 22 hours ago
What package manager? There is not a lockfile checked into your reproduction. Also please provide the output of payload info
.
Also, either you're using an outdated create-payload-app, or create-payload-app wasn't used in creating your reproduction.
Whenever a project is made using cpa, an .npmrc
file is written that contains legacy-peer-deps=true
in it, which will handle automatically installing peer dependencies.
This is the file tree for blank
.
├── .env.example
├── .eslintrc.cjs
├── .gitignore
├── .npmrc
├── .prettierrc.json
├── .yarnrc
├── Dockerfile
├── README.md
├── docker-compose.yml
├── next.config.mjs
├── package-lock.json
├── package.json
├── src
│ ├── app
│ ├── collections
│ ├── payload-types.ts
│ └── payload.config.ts
└── tsconfig.json
i am having same issue , installed nextjs , run npx create-payload-app
i am having same issue , installed nextjs , run npx create-payload-app
Hey @SaidBahaDev
Run npm install @floating-ui/react react-onclickoutside
and it should work.
i am having same issue , installed nextjs , run npx create-payload-app
Hey @SaidBahaDev
Run
npm install @floating-ui/react react-onclickoutside
and it should work.
thnks i installed both with --legacy-peer-deps and it works, i tested new nextjs and payload with pnpm and i didnt get the same error for @floating-ui/react, react-onclickoutside but i had it for sharp, installed it and its fixed.
Describe the Bug
Salam everyone.
I have created a Next.JS application using
npx create-next-app@latest
then initialised Payload usingnpx create-payload-app
.When I navigated to
/admin
an error occurred saying something likeUnable to resolve @floating-ui/react
.When I have downloaded
@floating-ui/react
andreact-onclickoutside
package, everything worked just fine.This is the commit for what I have done to fix it in my repository: https://github.com/shawqicauses/shawqi-stack/commit/8140c6cd0d9bbfc54f8be0f6dc28d1fd8aad0cf0
Thanks.
Link to the code that reproduces this issue
https://github.com/shawqicauses/shawqi-stack
Reproduction Steps
npx create-next-app@latest
npx create-payload-app
Which area(s) are affected? (Select all that apply)
area: core
Environment Info