I'm working with a JavaScript array that looks like this:
["X1", " X2", " X3", " X4", " X5", " X6", " X YZ1", " X YZ2", " X7", " X8", " X9"]
I need to remove the empty spaces before any letter starts, except for cases like X YZ1 where there is space between characters.
Can anyone help me with this issue?
Thanks in advance!
Best regards.