I need to get text from html element to use it in other checking.
But this checking must be done elsewhere later, not inside function of text getting.
That's why such variant as
> cy.get('#at__title').invoke('text').then((storedValue) => {
> storedValue
> })
doesn't suite, because I can use text only inside then
.
Also I tried to use
> cy.get('#at__title').invoke('text').as('element_text')
> this.element_text
but console log shows this.element_text
as undefined.