From 61356f99b9eaaf7eedd1e6ca1af09075b29a7920 Mon Sep 17 00:00:00 2001 From: Marco Montalbano Date: Fri, 12 Jul 2024 15:51:35 +0200 Subject: [PATCH] chore: update nextjs readme --- examples/nextjs/README.md | 36 ------------------------------------ examples/nextjs/readme.md | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+), 36 deletions(-) delete mode 100644 examples/nextjs/README.md create mode 100644 examples/nextjs/readme.md diff --git a/examples/nextjs/README.md b/examples/nextjs/README.md deleted file mode 100644 index c403366..0000000 --- a/examples/nextjs/README.md +++ /dev/null @@ -1,36 +0,0 @@ -This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app). - -## Getting Started - -First, run the development server: - -```bash -npm run dev -# or -yarn dev -# or -pnpm dev -# or -bun dev -``` - -Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. - -You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file. - -This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font. - -## Learn More - -To learn more about Next.js, take a look at the following resources: - -- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API. -- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial. - -You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome! - -## Deploy on Vercel - -The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js. - -Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details. diff --git a/examples/nextjs/readme.md b/examples/nextjs/readme.md new file mode 100644 index 0000000..f233ff7 --- /dev/null +++ b/examples/nextjs/readme.md @@ -0,0 +1,38 @@ +# Next.js + +This example aims to test the `js-auth` library on Vercel and Netlify edges. + + +## Vercel + +### Build settings + +- Framework Preset: `Next.js` +- Build Command: `pnpm --prefix ../../ build && pnpm build` +- Install Command: `pnpm --prefix ../../ install && pnpm install` +- Root Directory: `examples/nextjs/` + +Vercel - build and development settings + +### Test link + +- https://commercelayer-js-auth-nextjs.vercel.app/ +- https://commercelayer-js-auth-nextjs.vercel.app/middleware +- https://commercelayer-js-auth-nextjs.vercel.app/api/test + +## Netlify + +### Build settings + +- Runtime: `Next.js` +- Base directory: `examples/nextjs/` +- Build command: `pnpm --prefix ../../ install && pnpm --prefix ../../ build && pnpm install && pnpm build` +- Publish directory: `examples/nextjs/.next` + +Netlify - build and development settings + +### Test link + +- https://commercelayer-js-auth-nextjs.netlify.app/ +- https://commercelayer-js-auth-nextjs.netlify.app/middleware +- https://commercelayer-js-auth-nextjs.netlify.app/api/test \ No newline at end of file