skip to Main Content

How to String Split in javascript

I have a string fullName = 'Ross beddy washington andres' I need to split this in to firstName, middleName and lastName. Rule to split the names: when receiving 2 words: 1st LastName / firstName when receiving 3 words: 1st LastName…

VIEW QUESTION
Back To Top
Search