How to get the number of elements with Cypress

Recently, when working with Cypress again, I’ve met the issue that I cannot get the number of elements with Cypress. If the element is not found, Cypress will fail the test, which is not the result. In this blog, let’s see how you can do it with Cypress.

Donald Le
2 min readAug 5, 2023

--

Photo by Alice Triquet on Unsplash

--

--

Donald Le

A passionate automation engineer who strongly believes in “A man can do anything he wants if he puts in the work”.