Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

page.getByText doesn't support RTL options #7310

Open
6 tasks done
kettanaito opened this issue Jan 20, 2025 · 0 comments
Open
6 tasks done

page.getByText doesn't support RTL options #7310

kettanaito opened this issue Jan 20, 2025 · 0 comments

Comments

@kettanaito
Copy link
Contributor

kettanaito commented Jan 20, 2025

Describe the bug

The page.getByText() locator, while being similar to RTL's .getByText(), doesn't support the normalizer and other options available in RTL.

I consider this a bug for two reasons:

  1. This difference in behavior isn't listed in Vitest's docs.
  2. The docs even reference RTL's docs, which I read as "Learn more about this API because it's quite the same".

I find options like normalizer quite lacking since I don't see how you would select an element which text content is broken by a non-text UI element (you'd use normalizer for that).

Reproduction

Unfortunately, this is a docs/implementation issue.

System Info

Used Package Manager

npm

Validations

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant