Regex in a property resets after pressing enter for next line — Cloud Customer Connect
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Regex in a property resets after pressing enter for next line

Summary:

Regex resets after new line in property

Content (please ensure you mask any confidential information):

We are using a regex inside a property which checks that at least 10 characters are written. The problem is that when the user inserts a new line inside the property the regex resets.

Below you can see what the system does :

9 characters Error

10 character Ok

New line in the comments and regex breaks even though the second line is also 10 characters

Any idea how we can correct that?

The regex used in the property is this : /^(?=.{10,}$).*$/

Version (include the version you are using, if applicable):

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!