Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

js how to remove unit separator code inside a string

I got a string that look like this

'deFG4209268392612927005702000004809357'

there are unit seperator code inside that string, in vs code it look like this
enter image description here

and sublime text, it look like this
enter image description here

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

I want to remove anything look like that in the string. what the proper regex for that ?

>Solution :

/[\u0000-\u001F\u007F-\u009F\xAD\u061C\u200B\u200E\u200F\u202A-\u202E\u2066-\u2069]/g. It covers all the standard unit operators being used.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading