Skip to content

An interactive web application designed to help developers test, build, and learn regular expressions. With its intuitive interface and powerful features, it simplifies the process of working with regex patterns.

License

Notifications You must be signed in to change notification settings

ThatSINEWAVE/RegexLab

Repository files navigation

RegexLab

RegexLab is an interactive web application designed to help developers test, build, and learn regular expressions. With its intuitive interface and powerful features, it simplifies the process of working with regex patterns.

Features

🧪 Regex Testing

  • Test your regex patterns against sample text
  • View detailed match information including position and groups
  • Predefined patterns for common use cases (email, phone, URL, password)
  • Support for regex flags (g, i, m)

🔨 Regex Builder

  • Visual builder for constructing regex patterns
  • Common character classes with one-click insertion
  • Quantifiers and anchors for precise pattern control
  • Custom character class creation
  • Copy functionality for easy reuse

📚 Quick Reference

  • Cheat sheet of common regex patterns
  • Easy-to-browse syntax reference

Installation

To run locally:

  1. Clone the repository:
    git clone https://github.com/ThatSINEWAVE/RegexLab.git
  2. Open index.html in your browser

Usage

  1. Test Regex Tab:

    • Enter a regex pattern or select from presets
    • Add optional flags
    • Input test string
    • Click "Run Test" to see matches
  2. Regex Builder Tab:

    • Click buttons to add regex components
    • Create custom character classes
    • Use the repeat modal for precise quantifiers
    • Copy the generated regex for use in your code
  3. Quick Reference Tab:

    • Browse common regex patterns and syntax

Technical Details

  • Frontend: Vanilla JavaScript, HTML5, CSS3
  • Responsive Design: Works on desktop and mobile devices
  • Accessibility: ARIA attributes for screen reader support
  • Performance: Lightweight with no external dependencies (except Font Awesome icons)

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

License

This project is licensed under the MIT License - see the LICENSE file for details.