Skip to content

yhzhu99/live-diff

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Live Diff Logo

Live Diff

Modern, real-time, and high-granularity code comparison tool.

License: MIT React Vite Tailwind CSS


Live Diff is a sophisticated, real-time, and interactive web tool built for developers and AI enthusiasts who need to pinpoint differences between text or code instantly. Featuring high-granularity diffing and support for 20+ languages, it offers a premium experience for comparing AI outputs, code snippets, or any text content.

🚀 Key Features

  • ⚡ Real-time Diffing: Instant feedback as you type or paste—no lag, no waiting.
  • 🌈 Smart Syntax Highlighting: Auto-detection or manual selection for 20+ languages including JS, TS, Python, TeX, and more.
  • 🌓 Adaptive Themes: Beautifully crafted Light and Dark modes that respect your eyes and OS preferences.
  • 📊 Live Insights: Word and character counts updated in real-time.
  • 🛠️ Professional Layout:
    • Split & Unified Views: Choose the best way to visualize changes with the click of a button or shortcut.
    • Resizable Workspace: Adjust the editor and diff preview heights to fit your flow.
    • Fullscreen Diff: Focus entirely on the changes with a distraction-free mode.
  • ⌨️ Keyboard First: Powerful shortcuts for every common action.
  • 💾 Persistent Workspace: Your settings (themes, heights, preferences) are automatically saved via LocalStorage.

🛠️ Built With

Tech Description
React 19 The foundation for a reactive and performant UI.
TypeScript Ensuring rock-solid type safety throughout the app.
Vite 7 Ultra-fast build and development experience.
Tailwind CSS 4 Modern styling for a sleek, responsive interface.
Monaco Editor The power of VS Code's editor right in your browser.

📦 Getting Started

Prerequisites

Installation

  1. Clone the repository

    git clone https://github.com/yhzhu99/live-diff.git
    cd live-diff
  2. Install dependencies

    npm install
  3. Launch the development server

    npm run dev
  4. Enjoy Open your browser to http://localhost:3000 and start comparing!

⌨️ Keyboard Shortcuts

Shortcut Action
Cmd/Ctrl + S Swap original and modified content
Cmd/Ctrl + E Clear all content
Cmd/Ctrl + F Toggle Fullscreen Mode
Cmd/Ctrl + U Toggle Unified/Side-by-Side view

📖 How to Use

  1. Input: Paste your original content on the left and modified content on the right.
  2. Configure: Use the Language selector or let the Auto-detect ✨ feature handle it.
  3. Compare: View highlights in the Diff Preview. Use Unified View for long documents.
  4. Export: Copy the modified content with a single click.

📄 License

Distributed under the MIT License. See LICENSE for more information.


Built with ❤️ by the Live Diff team.

About

A modern, real-time, and interactive code comparison tool

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published