Can anyone assist me with validating input using regEx in Vue? I'm struggling to create one and haven't been able to find the correct pattern online for what I need.
The specific validation I am attempting is for a price value that should be a float with 2 decimal places. It can have either 1 digit before the decimal point, or up to 9 digits. For example:
0.50
1.00
99999.99
999999999.00
I attempted the following regEx pattern:
v => (/\d{1,3}(?:[.,]\d{3})*(?:[.,]\d{2})/.test(v))
However, it did not work as expected.
Please excuse any language barriers as English is not my native language. Any help would be greatly appreciated!