Skip to content

RamirezPineda/backend-belibeli

Repository files navigation

Ecommerce BeliBeli (Backend)

Static Badge Static Badge Static Badge Static Badge Static Badge Static Badge

Description

An e-commerce project to sell products online.

Previous requirements

Node version >=20.12.0

Installation

  1. Clone the repository
git clone https://github.com/RamirezPineda/backend-belibeli.git
  1. Navigate to the application directory:
cd backend-belibeli
  1. Install the project dependencies:
npm install

Configuration

Rename the .env.example file to .env and set the environment variables

# before
|--src
|--tests
|--.env.example
...
...
...
|--vitest.config.ts

# after
|--src
|--tests
|--.env
...
...
...
|--vitest.config.ts

Run the database migration script

npm run db:migrate

Running the app

# development
npm run dev

# production
npm run build
npm run start

Test

# unit tests
npm run test

# test coverage
npm run test:coverage

Linting

To run the linter you can execute:

npm run lint

And for trying to fix lint issues automatically, you can run:

npm run lint:fix