1๐
/^\+?[0-9]+$/g
^
asserts position at start of a line\+
matches the character +?
matches the
previous token between zero and one times- Match a single character present in the list
[0-9]
+
matches the previous token between one and unlimited times$
asserts position at the end of a line/g
Global modifier, return all matches
๐คSani Huttunen
Source:stackexchange.com