§

പാറ്റേൺ

ഫ്ലാഗുകൾ
§

ടെസ്റ്റ് സ്ട്രിംഗ്

§

മാച്ചുകൾ

0 മാച്ചുകൾ

    ഇതുവരെ matches ഒന്നും ഇല്ല — മുകളിൽ pattern, test string ടൈപ്പ് ചെയ്യൂ.

    §

    Replace മോഡ്

    ദ്രുത റഫറൻസ്

    Character ക്ലാസ്സുകൾ

    \d
    ഏത് digit-ഉം, [0-9]-ഉ തുല്യം.
    \w
    ഏത് word character-ഉം — letters, digits, underscore.
    \s
    ഏത് whitespace-ഉം — space, tab, newline.

    ആങ്കറുകൾ

    \b
    ഒരു word boundary-ൽ zero-width assertion.
    ^
    Input-ന്റെ start (m flag set ആകുമ്പോൾ ഓരോ line-ന്റെ start).
    $
    Input-ന്റെ end (m flag set ആകുമ്പോൾ ഓരോ line-ന്റെ end).

    ക്വാണ്ടിഫയറുകൾ

    *
    Previous token-ന്റെ zero or more, greedy.
    +
    Previous token-ന്റെ one or more, greedy.
    ?
    Previous token-ന്റെ zero or one — preceding quantifier lazy ആക്കുന്നു.
    {n,m}
    Previous token-ന്റെ n മുതൽ m repetitions.

    ഗ്രൂപ്പുകൾ

    (...)
    Capturing group — replacements-ൽ $1, $2, … ആയി expose ചെയ്യുന്നു.
    (?:...)
    Non-capturing group — slot consume ചെയ്യാതെ group ചെയ്യുന്നു.
    (?...)
    Named capturing group — replacements-ൽ $ ആയി expose ചെയ്യുന്നു.

    Lookaround

    (?=...)
    Positive lookahead — ശേഷം … ഉണ്ടെങ്കിൽ മാത്രം match ചെയ്യൂ
    (?!...)
    Negative lookahead — ശേഷം … ഇല്ലെങ്കിൽ മാത്രം match ചെയ്യൂ
    (?<=...)
    Positive lookbehind — മുൻപ് … ഉണ്ടെങ്കിൽ മാത്രം match ചെയ്യൂ
    (?
    Negative lookbehind — മുൻപ് … ഇല്ലെങ്കിൽ മാത്രം match ചെയ്യൂ

    Escapes

    \\
    ഒരു literal backslash character.
    \.
    ഒരു literal dot — ഏത് metacharacter-ഉം literally match ചെയ്യാൻ escape ചെയ്യൂ.

    കേരളത്തിൽ JavaScript regex ദൈനംദിന ഡെവലപ്പർ ജോലിയുടെ ഭാഗമാണ് — React form validation-ൽ email/phone format check ചെയ്യൽ, Node.js Express handler-ൽ input sanitise ചെയ്യൽ, KSRTC/KWA API log-ൽ error pattern scrape ചെയ്യൽ, Flutter/Dart ആപ്ലിക്കേഷനിൽ pincode format enforce ചെയ്യൽ. ഈ tester production-ൽ run ആകുന്ന അതേ browser RegExp engine ഉപയോഗിക്കുന്നു — ഇവിടെ test ചെയ്ത pattern code-ൽ bit-identical ആയിരിക്കും.

    ബ്രൗസറിൽ regex എങ്ങനെ പ്രവർത്തിക്കുന്നു?

    ഓരോ JavaScript runtime-ഉം ഒരു native regular expression engine ship ചെയ്യുന്നു — new RegExp(pattern, flags) pattern compile ചെയ്യുന്നു, String.prototype.match, String.prototype.replace, RegExp.prototype.exec ഏത് input string-ഉ നേരെ drive ചെയ്യുന്നു. ഈ tester ആ engine ഒരു UI-ൽ wrap ചെയ്ത്, browser വിടാതെ patterns edit, run, inspect ചെയ്യാൻ കഴിയുന്നു. Pattern, flags, test string, replacement — ഒന്നും network-ലേക്ക് send ചെയ്യുന്നില്ല.

    Regex tester എങ്ങനെ പ്രവർത്തിക്കുന്നു?

    Pipeline ഏതാനും ചുരുങ്ങിയ ഘട്ടങ്ങൾ — ഓരോ keystroke-ഉം client-side run ചെയ്യുന്നു (150 ms debounce, typing fluid ആകാൻ):

    1. മുകളിലെ input-ൽ നിന്ന് pattern body read ചെയ്യുന്നു (leading/trailing / delimiters ഇല്ല — decorative). തിരഞ്ഞെടുത്ത flag pills gi അല്ലെങ്കിൽ gimsuy പോലെ flags string ആക്കുന്നു.
    2. new RegExp(patternBody, flags) pattern compile ചെയ്യുന്നു. Engine ഒരു SyntaxError throw ചെയ്‌താൽ (unmatched parenthesis, invalid escape) message test string-ഉ മുകളിൽ render ചെയ്യുന്നു. Compile error V8 / SpiderMonkey / JavaScriptCore-ൽ നിന്നുള്ള actual err.message — DevTools-ൽ കാണുന്നത് തന്നെ.
    3. Match list-നായി, tester synthetic global flag ഉപയോഗിച്ച് enumerate ചെയ്യുന്നു — g off ആണെങ്കിലും list എല്ലാ matches-ഉം കാണിക്കുന്നു. Standard zero-width-match guard (if (m.index === rx.lastIndex) rx.lastIndex++) empty string match ആകുന്ന patterns-ൽ loop spin ആകാതെ കാക്കുന്നു. Replace mode real flag set honour ചെയ്യുന്നു.
    4. ഓരോ iteration-ഉം ഇടയ്ക്ക് tester performance.now() - start check ചെയ്ത് 50 ms കഴിഞ്ഞ ശേഷം abort ചെയ്യുന്നു. (a+)+$ ദീർഘ a-ക്കെതിരെ — tab hang ആകാതിരിക്കാൻ ഇത് catastrophic backtracking guard ചെയ്യുന്നു. Explanatory error ദൃശ്യമാകുന്നു, page ഉടൻ recover ചെയ്യുന്നു.
    5. Test string ഓരോ match-ന്റെ range-ൽ segments ആക്കി matched segments <mark class="rx-match rx-cap-N"> elements-ൽ wrap ചെയ്യുന്നു, N ആറ് palette colours-ൽ cycle ചെയ്യുന്നു. Numbered groups (m[1], m[2]) ഉം named groups (m.groups) ഉം labelled rows ആയി render ചെയ്യുന്നു; d flag set ആണെങ്കിൽ per-group [start, end] indices കാണിക്കുന്നു.

    ഈ regex tester ഉപയോഗിക്കേണ്ടത് എന്തുകൊണ്ട്?

    • Privacy: ഓരോ pattern, test string, replacement — browser-ൽ built-in JavaScript RegExp engine ഉപയോഗിച്ച് run ചെയ്യുന്നു. Tab-ൽ നിന്ന് ഒന്നും പോകുന്നില്ല — customer log, leaked credential pattern, hosted SaaS regex playground-ൽ paste ചെയ്യാൻ ആഗ്രഹിക്കാത്ത ഏത് input-ഉം safely test ചെയ്യാം.
    • Honest flavor: Node.js, Chrome, Safari, Firefox, ഓരോ browser-based form validator — ഇവ run ചെയ്യുന്ന exact regex engine tester expose ചെയ്യുന്നു. Perl-flavor translation layer ഇല്ല — ഇവിടെ work ചെയ്യുന്നത് code-ൽ work ചെയ്യുന്നു.
    • Capture, named-group debugging: ഓരോ match-ഉം numbered group ($1, $2, …), named group ($<year>) per match show ചെയ്യുന്നു — parser build ചെയ്ത് slots guess ചെയ്യാതെ read ചെയ്യൂ. Replace mode groups freely mix ചെയ്യൂ.
    • Catastrophic-backtracking guard: 50 ms ceiling (a+)+$ പോലെ pathological patterns tab freeze ആകുന്നതിന് മുൻപ് abort ചെയ്യുന്നു. Hung browser-ഉ പകരം explanatory error ദൃശ്യമാകുന്നു, page ഉടൻ recover ചെയ്യുന്നു.

    Regex tester-ന്റെ പൊതു ആപ്ലിക്കേഷനുകൾ?

    Web development, security, data work-ൽ regular expressions ഉണ്ടാകും — ഈ tester ഏറ്റവും പൊതുവായ use cases target ചെയ്യുന്നു:

    • Form validation: email, phone, postal-code pattern prototype ചെയ്ത്, sample inputs test string-ൽ paste ചെയ്ത്, production code-ലേക്ക് ship ചെയ്യുന്നതിന് മുൻപ് ഓരോ positive case match ആകുന്നുണ്ടോ, negative case match ആകുന്നില്ലേ confirm ചെയ്യൂ.
    • Log scraping: NGINX, application, audit-log output ഒരു chunk paste ചെയ്ത്, ആവശ്യമായ parts-ന് named groups ഉള്ള pattern എഴുതൂ ((?<ip>…) (?<path>…)), captured slots per match confirm ചെയ്ത് parser correct ആണോ verify ചെയ്യൂ.
    • Refactor search-and-replace: Replace mode ഉപയോഗിച്ച് ഒരു snippet-ൽ identifiers rewrite ചെയ്യൂ — (\w+)\.set(\w+)\($1.$2 = getter calls property assignments ആക്കുന്നു, codemod-ൽ commit ചെയ്യുന്നതിന് മുൻപ് live preview ഫലം കാണിക്കുന്നു.

    ഒരു regex example എങ്ങനെ ഇരിക്കും?

    Pattern (\d{4})-(\d{2})-(\d{2}), g flag, test string release 2025-11-15, prerelease 2026-05-25. Engine രണ്ട് matches കണ്ടെത്തുന്നു. ആദ്യ match 2025-11-15, group 1 = 2025, group 2 = 11, group 3 = 15. രണ്ടാം match 2026-05-25. Replace mode-ൽ, replacement template $3/$2/$1 രണ്ട് dates-ഉം 15/11/2025, 25/05/2026 ആക്കി rewrite ചെയ്യുന്നു — script-ൽ plug ചെയ്യുന്നതിന് മുൻപ് visually verify ചെയ്യാൻ കഴിയുന്ന ഒരൊറ്റ-pattern ISO-to-DMY conversion.

    ഏത് regex ജോലിക്കും — building, debugging, rewriting — ഈ tester fast path ആയി ഉപയോഗിക്കൂ. Everything locally run ചെയ്യുന്നു; ഒന്നും log ചെയ്യുന്നില്ല; regex engine browser ship ചെയ്യുന്നതാണ്, production code runtime-ൽ കാണുന്ന behaviour-ഇ ഒരേ.