Code Monkey home page Code Monkey logo

url_shortener's Introduction

rejus.link (A URL shortener)

Collaborators
liambrockpy โ˜ž
JLP2000 โ˜ž

Built with Flask, rejus.link is a simple URL shortener app with QR code image generation.

Running live on rejus.link

Deployed using gunicorn and nginx on an AWS EC2 instance.

Technologies

  • Python
  • JavaScript
  • Flask:
    • flask-wtf
    • flask-sqlalchemy
    • flask-migrate
  • qrcode
  • pytest
  • python-dotenv
  • psycopg2-binary
  • PostgreSQL (ElephantSQL)
  • gunicorn
  • nginx
  • AWS

Process

Wins and Challenges

Wins

  • Displays history of links created with removal functionality
  • Successfully deployed and hosted on AWS using custom domain name with SSL Certification

Challenges

  • One initial challenge we faced was if users input a URL with just the domain name, if that was retrieved from the database and used as a href attribute within links, it would see it as relative URL and not external. We therefore built a simple URL parser to add http:// prefixes to URLs. As a bonus side effect, this also helped reduce possible duplicates within the database too.
  • Another fun challenge was creating a recent history of links created using local storage. On first look we realised "oh, you can only store strings, but we need to save the long and shortened url together!". With further reading we discovered we could stringify the data into JSON strings and just parse it back to JavaScript when we needed to display the data.

Future features

  • Analytics (e.g. clicks on shortened links) - DB table modifications
  • Richer styling including animations with Framer

url_shortener's People

Contributors

liambrockpy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.