JSFiddle - React, Tailwind, and code Playground

by John Wick

JavaScript

/*
var application = {
  "applicantId": "99526e21-28b4-40c3-8ac8-bbb040d94056",
  "isActive": true,
  "lineOfBusiness": "PERSONAL",
  "metadata": {
    "revenuePartnerId": "a031b000002YnOeAAK",
    "affiliateDataId": "2a417f68-e85c-460b-94e7-ddf822a800bb",
    "googleAnalyticsUserId": "afd18a39-ca73-4074-944a-5a98ae9579ec",
    "product": "HOME",
    "source": "MindOfMyloBuyflows"
  },
  "tenantId": "mylo",
  "id": "7c64ae0e-14f3-4882-867e-376cfe70e89a",
  "createdAt": "2023-05-16T09:46:53.922Z",
  "updatedAt": "2023-05-16T09:46:53.922Z",
  "version": "a847bdc9-d9d4-4d7e-91ac-e72397746d41"
}

var agent = {
	firstname: 'john',
  lastname: 'doe'
}
var xxx = Object.assign({}, application.metadata, agent)
console.log("xxx:", xxx);
*/

var options = {
 agent: {
 	firstName: 'john',
    email: '[email protected]'
 }
}

var options1 = {}
var sss = {
    agent: { ...options.agent }
}


console.log(JSON.stringify(sss,'',2));