Simplify your stack and build anything. Or everything.
Build tomorrow’s web with a modern solution you truly own.
Code-based nature means you can build on top of it to power anything.
It’s time to take back your content infrastructure.

Specify where payload can find payload.config.ts

default discord avatar
warrensadlerlast year
2

Hello everyone, I'm working on setting up payload in a nx-monorepo. I'm going the self-installation route by attaching payload to an existing express application but am getting a compilation error when starting the dev server.



Payload can't locate

payload.config.ts

. I'm thinkig it could be resolved if I could give payload a hint on where to locate the config file.



Here's a sample repo for review:

https://github.com/warren-sadler/payload-cms-nx

I've included screen caps of my source tree and the stacktrace I see.

  • default discord avatar
    notchrlast year
    @986791298398834689

    That is defined in your package.json commands



    or via ENV variable



    "PAYLOAD_CONFIG_PATH"



    Check out your

    .env

    file first to see if changing it there fixes things

  • default discord avatar
    warrensadlerlast year

    That did the trick

    @1049775120559898725

    , that was the solution! Now I'm facing some other issues getting payload to play nicely with NX. I appreciate your help!

Star on GitHub

Star

Chat on Discord

Discord

online

Can't find what you're looking for?

Get dedicated engineering support directly from the Payload team.