title: Category shorthand not allowed in this regular expression dialect in TypeScript
body: <p>I tried to use a regular expression in TypeScript:</p>
  <pre><code>const pass = /^[\pL\pM\pN_-]+$/u.test(control.value) || !control.value;
  </code></pre>
  <p>but I got this error:</p>
  <blockquote>
  <p>Category shorthand not allowed in this regular expression dialect in Typescript</p>
  </blockquote>
  <p>Why am I getting this error, and how can I fix it?</p>