I wanted to create a minimal payload / nextjs app without the template boilerplate, so I did
yarn add @payloadcms/next-payload payload
yarn next-payload install
... the project runs fine both with
... but when I deploy to vercel, I get the following error:
Error: Error: cannot find Payload config. Please create a configuration file located at the root of your current working directory called "payload.config.js" or "payload.config.ts".
I've tried duplicating the payload.config.ts file in multiple places, including the root as well as the
folder ... the
is being properly set (
configPath: path.resolve(__dirname, './payload/payload.config.ts'),
), and I've tried all variations of path in root, with and without the starting
... does anyone have any ideas?
Have you tried setting the config property as shown in step 4 here:https://github.com/payloadcms/next-payload
ugh - that was it ... thank you!