Skip to content

Sorta is a website built using Flask HTML Tailwind CSS and Javascript which helps users visualize sorting algorithms like bubble sort, merge sort etc. with animations made for Axiom (HackClub YSWS)

License

Notifications You must be signed in to change notification settings

Rexaintreal/Sorta

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sorta Logo

Sorta

Visualize sorting alogrithms in Increasing order with step by step animations and explore various techniques using Sorta. This Project was made for the Axiom YSWS

GitHub Axiom Hackatime Flask JavaScript TailwindCSS


About

Sorta features a clean minimal UI built with TailwindCSS and smooth sorting animations powered by JavaScript It offers the top six sorting algorithms Bubble Sort, Insertion Sort, Merge Sort, Quick Sort, Selection Sort, and Heap Sort with example code in five languages. You can edit the values in the array or list, as well as the length. Sorta is hosted on PythonAnywhere at LINK try it and share your feedback! I made this project for Axiom YSWS a Hack Club YSWS


Demo Video

The Demo video where I show all the sorting visualization

DEMO


Try it (ITS LIVE)

Sorta is hosted on PythonAnywhere and you can visit it at LINK

Features

  • Clean minimal UI
  • Six sorting algorithms with visuals
  • Example code in five languages
  • Smooth step by step animations
  • Editable array values and length

Project Structure

Sorta/           
├── static/               
│   ├── assets/          # Logo files and favicon
│   ├── css/             # global style
│   └── js/              # animation and other logic
├── templates/           # HTML templates for all the pages
├── .gitignore           # Git ignore file
├── app.py               # Main Flask application with all routes
├── LICENSE              # MIT License
├── README.md            # You are reading this hehe
└── requirements.txt     # Python dependencies (only Flask)

Setup and Installation

Prerequisites

  • Python 3.13+ (I used 3.13.5 but anything 3.13+ should work)
  • pip for installing packages

Installation Steps

  1. Clone the repository:

    git clone https://github.com/Rexaintreal/Sorta.git
    cd Sorta
  2. Create a virtual environment (recommended):

    This keeps things clean and doesn't mess with your other Python projects (i dont usually do it T_T)

    Windows:

    python -m venv venv
    .\venv\Scripts\activate

    macOS / Linux:

    python3 -m venv venv
    source venv/bin/activate
  3. Install dependencies:

    pip install -r requirements.txt
  4. Run the app:

    python app.py
  5. Open it up:

    Go to http://127.0.0.1:5000 in your browser


Technical Details

Sorta’s sorting visualizations are built with a lightweight stack and run fully on the client side (the browser)

  • HTML + TailwindCSS for the layout, UI, and responsive design
  • Vanilla JavaScript for generating steps handling animations and controlling play/pause/step logic
  • requestAnimationFrame for smooth frame-based animations during swaps comparisons and transitions
  • DOM rendering to rebuild and update the array boxes highlights and sorted states
  • Flask is used only for routing the pages and there is no heavy backend logic or database

All sorting steps (compare swap no swap sorted complete) are created in JavaScript and saved in a array Then the animator just reads each step one by one and updates the screen in real time Every sorting algorithm follows the same pattern


License

MIT LICENSE.


Acknowledgements

  • GeeksforGeeks — for multi-language example code used as reference

You may also like...

Some other projects I've built:


Author

Built by Saurabh Tiwari

About

Sorta is a website built using Flask HTML Tailwind CSS and Javascript which helps users visualize sorting algorithms like bubble sort, merge sort etc. with animations made for Axiom (HackClub YSWS)

Topics

Resources

License

Stars

Watchers

Forks

Languages