An open API service indexing awesome lists of open source software.

https://github.com/zeeshanalico/url-shortner

The URL Shortener app is a powerful and user-friendly tool designed to transform long and cumbersome web links into concise, easy-to-share URLs. Ideal for both individuals and businesses. You can also pregenerate shortlinks to reserve them for future use. Can see the statistics of shorturl.
https://github.com/zeeshanalico/url-shortner

chartjs http javascript jwt multer nestjs nestjs-backend postgresql prisma-client prisma-orm redux redux-thunk redux-toolkit resful-api restful-webservices rtk-query tailwindcss typescript winston

Last synced: about 2 months ago
JSON representation

The URL Shortener app is a powerful and user-friendly tool designed to transform long and cumbersome web links into concise, easy-to-share URLs. Ideal for both individuals and businesses. You can also pregenerate shortlinks to reserve them for future use. Can see the statistics of shorturl.

Awesome Lists containing this project

README

        

## Prerequisites

- Node.js and npm installed
- PostgresSQL installed

## Overview

This project consists of the client and the server dir. The client is a frontend application developed in nextjs, while the server(nestjs) handles the backend logic and interacts with the database.

### Clone the Repository

First, clone the repository to your local machine:
```bash
git clone https://github.com/zeeshanalico/URL-Shortner.git
```
configure/restore the database
```bash
cd DB
create -U username -c "dbname"
psql -U username dbname < backup.sql
```

## Environment Variables

add a .env.development or .env.production file in server directory with the following environment variables

`MY_PORT` as server port like e.g. 3000
`MY_BASE_URL` e.g. http://localhost:3000
`DATABASE_URL` e.g. postgresql://postgres:admin@localhost:5432/tbsh?schema=public
`SECRET_KEY` any random string

add a .env.development or .env.production file in client directory with the following environment variables
`NEXT_PUBLIC_SERVER_URL`

## Running the Server side of app

```bash
#install dependencies
$ npm install

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod
```

## Running the Client side of app

```bash
#install dependencies
$ npm install

# development
$ npm run dev
```

## Stay in touch

- Author - [Zeeshan Ali](https://linkedin.com/in/zeeshanalico)

#NextJs
#Nestjs
#Prisma
#Postgres