a3aa6590ff
We already had `domains` as "not recommended" but this PR marks it as "deprecated" and prints a warning if its detected. I also updated all examples to switch from `domains` to `remotePatterns`. |
||
---|---|---|
.. | ||
app | ||
components | ||
css | ||
pages/api | ||
payload | ||
public | ||
utilities | ||
.env.example | ||
.gitignore | ||
.npmrc | ||
cssVariables.js | ||
next-env.d.ts | ||
next-env.scss.d.ts | ||
next.config.js | ||
package.json | ||
payload-types.ts | ||
README.md | ||
tsconfig.json |
Next + Payload Serverless Demo
This is a demo showing how to utilize @payloadcms/next-payload
to deploy Payload serverlessly, in the same repo alongside of a Next.js app.
Deploy your own
Deploy the example using Vercel:
How to use
Execute create-next-app
with npm, Yarn, or pnpm to bootstrap the example:
npx create-next-app --example cms-payload cms-payload-app
yarn create next-app --example cms-payload cms-payload-app
pnpm create next-app --example cms-payload cms-payload-app
Deploy it to the cloud with Vercel (Documentation).
The only thing you need to do to deploy to Vercel is to ensure that you have a Mongo Atlas database connection string and an S3 bucket (if desired).
Fill out the same environment variables that are shown in the .env.example
with your own values, and then you're good to go!
Developing locally
To develop with this package locally, make sure you have the following required software:
- MongoDB
- Node + NPM / Yarn
- An S3 bucket to store media (optional)
Getting started
Follow the steps below to spin up a local dev environment:
- Clone the repo
- Run
yarn
ornpm install
- Run
cp .env.example .env
and fill out all ENV variables as shown - Run
yarn dev
to start up the dev server
From there, you can visit your admin panel via navigating to http://localhost:3000/admin
. Go ahead and start working!