JavaScript code to split names into their respective components (first, last, etc)