Exclamation mark bypasses regex [duplicate]

Discussão em 'Angular' iniciado por el sparrow, Abril 2, 2025.

  1. el sparrow

    el sparrow Guest

    I have an angular application with a form using formbuilder. I added a validator using this regex on my input:

    ^[A-Za-zÀ-ÖØ-öø-ÿœŒŸ \-']{1,50}$ on one of my input "name"

    The problem is when the name contains exclamation mark ! the error pattern does not tell me the input is invalid, the form is shown as valid, is there something I am missing? thanks for your help

    Continue reading...

Compartilhe esta Página