T
TanStack11mo ago
ugly-tan

How to use Tanstack Router with Playwright Component Testing

Im trying to migrate a project to Tanstack Router and can't figure out how to use it in playwright component tests. Has anyone successfully done this before?
4 Replies
xenial-black
xenial-black11mo ago
what exactly do you want to test? how does router come into play here?
ugly-tan
ugly-tanOP11mo ago
I have a component that uses Route.useSearch This project was previously on react-router where I could easily mount the route component in the test.
ugly-tan
ugly-tanOP11mo ago
That didn't seem to work for me. I'll see if I can get a minimal example in GitHub this weekend

Did you find this page helpful?