I have many strings like this:
0001, 0002, ..., 0010, 0011, ..., 0100, 0101,...
I would like these to become like this:
1, 2, ..., 10, 11, ..., 100, 101, ...
So I would like to remove all the 0
chars before a different char is present.
I tried with
.replace(/0/g, '')
But of course then it also removes the 0
chars after. Therefore for example 0010
becomes 1
instead of 10
. Can you please help me?