Make sure you have the following installed:
- Node.js (v16 or later)
- npm or yarn
- Firebase CLI (if using Firebase for the backend)
-
Navigate to the frontend directory:
cd frontend -
Install dependencies:
npm install # or yarn install -
Start the development server:
npm run dev # or yarn dev -
Open http://localhost:3000 in your browser to view the app.
-
Navigate to the backend directory:
cd backend -
Install dependencies:
npm install # or yarn install -
Start the backend server:
npm run dev # or yarn dev -
The backend server will run on http://localhost:5000 (or the port specified in your backend configuration).
Create a .env file in the backend directory and add the following:
PORT=5000
DATABASE_URL=your-database-url
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.
For backend development, refer to the documentation of the backend framework or tools you're using (e.g., Express.js, Firebase, etc.).
The easiest way to deploy your Next.js app is to use the Vercel Platform.
You can deploy the backend to platforms like:
Check the respective platform's documentation for deployment instructions.