Cypress v3, v4
Our typescript definition for cy.its command "understands" the properties of the subject, thus it can do
cy.wrap({ foo: 1 }).its('foo') // yup, subject has property "foo"
but it does not understand nested (compound) properties that Lodash _.get can do and we use under the hood
cy.wrap({
foo: {
bar: 1
}
}).its('foo.bar') // oops, TypeScript freaks out, "foo.bar" is invalid
Maybe someone can look at Lodash and its TypeScript definition for _.get to see if they have solved this problem and bring the solution?
Cypress v3, v4
Our typescript definition for
cy.itscommand "understands" the properties of the subject, thus it can dobut it does not understand nested (compound) properties that Lodash
_.getcan do and we use under the hoodMaybe someone can look at Lodash and its TypeScript definition for
_.getto see if they have solved this problem and bring the solution?