To play with a deployed version of the application go to: trello-clone
This is a Next.js project bootstrapped with create-next-app
.
First, run the development server:
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
- change
.env-example
to.env
- fill the relevant environment variables - for each site (clerk, unsplash, stripe)follow site guidelines
Open http://localhost:3000 with your browser to see the result.
- Database
- database:
- MySql as database
- Prisma as ORM
- database hosting filess.io
- initial worked with MySQL in docker -> due to issues with deploying db host in Vercel moved to filess.io
- during development the DB was deployed inside a docker (see docket-compose.yml), due to issues with deploying the db in vercel host I moved to filess.io as db host.
- database:
- Authentication - clerk
- Style - tailwind.css
- shadcn-ui - Re-usable components above radix-ui & tailwind.css
- Icons - lucide - with react package
- Payment - stripe
- State management - zustand
- Schema validation - zod
- (SHOULD BE DONE ONLY ON DEV!!) Reset the DB:
npx prisma migrate reset
- push new schema(s) to db:
npx prisma db push
- create the new schema(s) locally:
npx prisma generate
- Visualize DB in browser - prisma studio:
npx prisma studio
(work well with docker, TBD::check how to make it work with filess.io)
In order to use/test stripe locally, you need to following:
- Login into stripe.com
- Go to dashboards and click the
developers
buttons - Click on webhooks tab
- Click on "Test in local environment":
https://dashboard.stripe.com/test/webhooks/create?endpoint_location=local
- Follow the instructions...make sure to keep the terminal open/running
- enter fake credit card information:
- the important fake information is the credit card number: 4242 4242 4242 4242
- the rest of the information is not really important for the testing purposes
Enabling billing portal (in development mode):
- Search for
billing portal
- Select
Customer portal
(should be under: Settings -> Customer portal) - Click on
activate test link
button
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.