Vote count:
0
I have strings that are like this:
var a = "Test";
or
var a = "AnotherTest";
I have full control over the contents of these strings and they contain either one or two words with the second word (if it appears) starting with a capital letter.
How can I create a variable from the above that splits on the upper case letter so that it would make these two strings:
var title = "Test";
var title = "Another Test";
asked 17 secs ago
How can I split the contents of a string when there's a capital letter?
Aucun commentaire:
Enregistrer un commentaire