Repository navigation
refactor: do not pollute markup with useless id - #225
Conversation
|
Hi! This is the solution I came up with, which makes all related-tests pass at once: https://github.com/testing-library/vue-testing-library/pull/137/files#diff-4f8b5837e5c68e71852f1c3f41f2e98201426d45a94bd7767cddfc98ccd02fc5R66-R68 re Right now, the PR testing-library/vue-testing-library#137 has all non commented out tests passing.
This is probably… sensible? I mean, people asked for special behavior when |
|
I could be wrong about how attachTo is currently working, that might already be the behavior. I will check. Either way this fix is still good. Seems like your fix in testing library is okay, is there anything else blocking the Vue 3 integration? |
Not really, I'm a bit worried about the third // testing lib with 2.x
render(Component, {}, vue => vue.use(AnAwesomePlugin))
// testing lib with 3.x
render(Component, { global: { plugins: [AnAwesomePlugin] } })however some people did quite complex trickery with the Vue instance. We'll see if the global options can keep it up, or if other libraries (such as Vue Apollo in the example) provide a "Vue-3 way" of achieving the same thing. Also, integration with VueRouter-next is not there yet, given that we haven't decided how to tackle it in VTU-next (AFAICT). I might go ahead and simply install it as a plugin, and see what happens in the wild. I guess I'll release an alpha version in the next channel soon, and see if people run into some issues. This might help dogfooding VTU-next, too! :) |
|
And yep - my experience so far is predicting things is hard, better just to get something out there and let people report issues. |
Related: #219
@afontcu seems we can remove this id. I am not sure about the div - what should we be attaching to?
Also, does testing library use
attachToby default? We need something to mount on - if you are using attachTo, however, maybe we can use that element to mount on, instead of creating our own DIV here?