Skip to content

URL Shortener using NodeJS on Express Framework and MongoDB integrated with Redis.

Notifications You must be signed in to change notification settings

utkarshgpta/slash-url

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SlashURL

This is a Node.JS web application powered by Express that provides the main functionality that you'd expect from a URL Shortener service.

Features

  • Fast
  • Lightweight
  • Minimalistic
  • REST API microservice
  • Other awesome features to be implemented

Motivation

The main motivation behind this project was to learn about NodeJS, MongoDB and integration of Redis as a secondary database and how it affects the overall performance of the web applications.

Usage and Demo

The project also contains a front-end and can be deployed easily on a platform(e.g. Heroku). The main motivation behind this project is to make use of REST API created to develop a browser extension

Demo Image

Setup

Clone this repo to your desktop and run npm install to install all the dependencies.

You might want to look into config.js to make change the port you want to use and any other required

Tech Used

SlashURL uses a number of open source projects to work properly:

  • node.js - evented I/O for the backend
  • Express - fast node.js network app framework
  • MongoDB - cross-platform document oriented database
  • Redis - open source in-memory database
  • Twitter Bootstrap - great UI boilerplate for modern web apps
  • jQuery - duh

Development

Want to contribute? Great! Let's set it up first.

Installation

SlashURL requires Node.js, MongoDB and Redis to run.

Open up the terminal and type the following command to fire up the instance of MongoDB.

$ mongod

Open another terminal and get to the project folder. Install the dependencies and start the server.

$ git clone https://github.com/UtkarshGpta/slash-url.git
$ cd slash-url
$ npm install -d
$ node start

You can also use Nodemon using nodemon app.js instead of npm start every time you make changes in the project.

To-Dos


  • Write tests for this app
  • Make a Chrome/Firefox extension using which we can select the URL to be shortened on the page, right click and select the option to shorten the URL, which then connects to our REST API, retrieves and copies to the clipboard - the shortened URL.

Acknowledgement

I started off learning about creating URL Shortener through this blog where they used Mongoose instead of Native Mongo driver.

About

URL Shortener using NodeJS on Express Framework and MongoDB integrated with Redis.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published