Rayrun
โ† Back to Discord Forum

How to check element visibility on actions

When using playwright action such as toHaveText, click. Do I need to use the visibility check separately? ~Thanks in advance... ๐Ÿ˜€

This thread is trying to answer question "Do I need to perform a separate visibility check on an element when using Playwright actions such as toHaveText or click?"

2 replies

Hi, no, you don't need to, it's redundant: https://playwright.dev/docs/actionability

(Except if it's another element you want to check for page readiness, like first check that the spinner is gone, then go ahead with other elements)

Thanks... ๐Ÿ‘ ๐Ÿ‘

Related Discord Threads

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email [email protected].