Node JS Code pour enregistrer le prénom et le nom de famille

var studentFullName="John Smith";
var details=[]
var details=studentFullName.split(' ');
console.log("StudentFirstName="+details[0])
console.log("StudentLastName="+details[1]);
Enthusiastic Earthworm