Here is a nifty trick: get from the document a form elements object and set multiple input values at once.
cy.document()
.its('forms.personal-info.elements')
.then(function (elements) {
elements['first-name'].value = 'Joe'
elements['last-name'].value = 'Smith'
elements.city.value = 'Boston'
})
For more, see the "Form recipes" at https://glebbahmutov.com/cypress-exam...