A dynamic tech news blog for developers, featuring user authentication, article management, and interactive discussions.
Before you begin, ensure you have met the following requirements:
- Node.js and npm installed on your machine.
- Git installed on your machine.
To get a local copy up and running, follow these simple steps.
- Clone the repository:
git clone git@github.com:MEZ901/InfoDev.git
- Navigate to the project directory:
cd InfoDev
- Install dependencies using npm:
npm install
You may need to configure some environment variables.
- Extract the
.env
file from the.env.example
file:cp .env.example .env
- Update on the environment variables.
Make sure you have created and set up your database configuration in the
.env
file before proceeding with these steps.
-
Run database migrations:
npm run db:migrate
-
Generate the Prisma Client code:
npm run prisma:generate
-
Seed the database with initial data (optional):
npm run db:seed
To run the application locally, you can use the following command:
npm run dev
PS: You have two options to access the application:
- Browser-Sync Version (Auto-Refresh):
- After running
npm run dev
, the Browser-Sync version of the application will be available athttp://localhost:3001
.- Browser-Sync will automatically refresh the page whenever you make changes to your EJS templates, providing a smooth development experience.
- Normal Version (Manual Refresh):
- The normal version of the application can be accessed at
http://localhost:3000
.- In this version, changes to your EJS templates may require manual page refreshing in your web browser.
Feel free to choose the version that best suits your development needs..
PS 2: We got some issues with the
Browser-Sync
package, so we recommend using the normal version of the application temporarily.