Skip to content

Free Modern URL Reducer. Make sure to share love by giving it a star.🌟 Have a great day!

License

Notifications You must be signed in to change notification settings

itsoriki/reduced.to

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Contributors Forks Stargazers Issues


logo

Preview

Reduced.to is a modern web application that reduces the length of link URL. So it's easier to remember, share and track.

App Β· Report Bug Β· Request Feature


πŸ“š Table of Contents
  1. 🌐 About The Project
  2. πŸš€ Getting Started
  3. πŸ±β€πŸ’» Usage
  4. 🧱 Roadmap
  5. πŸ₯‡ Contributing
  6. πŸ† Contributors
  7. πŸ“ License
  8. πŸ’Œ Contact

🌐 About The Project

πŸ”₯ Built With

List of frameworks/libraries used to bootstrap the project.

  • NX
  • Nest
  • Qwik
  • Tailwindcss
  • Novu

(back to top)

πŸš€ Getting Started

πŸ“ƒ Prerequisites

List of things you need to run the project locally and how to install them.

  • npm
    npm install npm@latest -g
  • docker
    https://docs.docker.com/get-docker/

πŸ’» Installation

  1. Fork / Clone this repository
  2. Install NPM packages
    npm install
  3. Copy .example.env to .env and fill it properly (see Configuration)
  4. Make sure you have a local instance of PostgreSQL running on port 5432. If not, you can run it using docker:
    docker run --name reduced_to_db -e POSTGRES_USER=postgres -e POSTGRES_PASSWORD=postgres -e POSTGRES_DB=reduced_to_db -p 5432:5432 -d postgres
  5. Run Prisma migration from root folder:
    npx nx migrate-dev prisma --name=init
  6. Run the backend from root folder:
    npx nx serve backend
  7. Run the frontend from root folder:
    npx nx serve frontend

πŸ‘©β€πŸ’» Development

The project is structured in the following way:

.
β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ backend
β”‚   └── frontend
└── libs/
    β”œβ”€β”€ config
    └── prisma

🐳 Docker

You can build the docker images by running the following nx command:

npx nx run-many -t docker-build
  • This command will automatically build the dependencies and the backend and frontend images.

πŸ™ Docker compose

  • In case you have docker installed, you can single-click deploy and test your changes by running the following and going to http://localhost:5000/ on your browser.

  • When you run the command below, don't forget to change the .env file with the correct values.

    docker compose -f docker/local/docker-compose.yml -p reduced-to up

πŸ‘· Configuration

For the minimal configuration you can just rename the .example.env files to .env.

General
  • BACKEND_APP_PORT: Backend port
  • FRONTEND_APP_PORT: Frontend port
  • NODE_ENV: Node environment (development / production)
Database
  • DATABASE_URL: Database connection string
Rate Limit
  • RATE_LIMIT_TTL: Rate limit TTL (time to live)
  • RATE_LIMIT_COUNT: Number of requests within the ttl
Logger
  • LOGGER_CONSOLE_THRESHOLD: Threshold level of the console transporter.
Frontend
  • DOMAIN: Domain of your frontend app
  • API_DOMAIN: Domain of your backend instance (used for server side requests)
  • CLIENTSIDE_API_DOMAIN: Domain of your backend instance (used for client side requests)
  • STORAGE_DOMAIN=Domain of your bucket (used for storing images)
Redis
  • REDIS_ENABLE: Whether to use external Redis store or not
  • REDIS_HOST: Redis instance host
  • REDIS_PORT: Redis instance port
  • REDIS_PASSWORD: Redis instance password
  • REDIS_TTL: Redis ttl (in seconds)
Auth
  • JWT_ACCESS_SECRET: Jwt secret (used for access tokens)
  • JWT_REFRESH_SECRET: Jwt secret (used for refresh tokens)
Safe Browsing API
Novu
  • NOVU_API_KEY: Get it from https://novu.co/, you don't need this when running locally (just verify your email from the database)

Happy Hacking !

(back to top)

πŸ±β€πŸ’» Usage

Simply copy and paste a URL into the provided area. Then click shorten URL! Your URL has now been shortened!

(back to top)

🧱 Roadmap

  • Migrate backend to NestJS
  • Migrate frontend to Qwik
  • Better README
  • Generate QRCode
  • Split front-end into components
  • Better UI
    • Animations
    • Logo
    • Dark/Light mode
  • Improve front-end components
  • Backend tests
  • Migration to Nx
  • Split backend into libs
  • Support k8s deployment (helm)
  • Front-end Tests
  • Logs
  • Add a statistics page
  • Add more ideas

Just create a Pull request already πŸ˜ƒ

See the open issues for a full list of proposed features (and known issues).

(back to top)

πŸ₯‡ Contributing

Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star ⭐!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ† Contributors

(back to top)

πŸ“ License

This project is licensed under the terms of the MIT License

(back to top)

πŸ’Œ Contact

Project Link: https://github.com/origranot/reduced.to

(back to top)

About

Free Modern URL Reducer. Make sure to share love by giving it a star.🌟 Have a great day!

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 96.9%
  • JavaScript 1.3%
  • CSS 1.3%
  • Dockerfile 0.5%