-
-
Notifications
You must be signed in to change notification settings - Fork 189
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
v-if on portal component does not work with target-el #163
Comments
Yeah IK'm pretty sure that this one of the side effects of the (honestly) half-assed implementation I did with In 2.0.0, we will have a For 1.* this will be a wontfix, though I would consider merging a fix if someone felt the need to send a PR. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
<portal to="destination">
<p>This slot content will be rendered wherever the <portal-target> with name 'destination'
is located.</p>
</portal>
<portal-target name="destination">
<!--
This component can be located anwhere in your App.
The slot content of the above portal component will be rendered here.
-->
</portal-target> How can I use outside of Vue app? |
@towry See here: https://linusborg.github.io/portal-vue/#/guide?id=rendering-outside-of-the-vue-app Make sure to omit the Vue template <portal target-el="#dialog">
<!-- ... -->
</portal>
<body>
<div id="app"></div>
<div id="dialog"></div>
</body> |
@morkro I thought the |
The targetEl feature is redone for upcoming 2.0, i won't remove it but change the implementation and API. The new implementation won't have these sorts of problems. |
This should work fine in 2.0 with the new |
Demo: https://codesandbox.io/s/0y2wqy9w3w
I'm not sure if this is a bug (and may work after #139) or expected behavior because of limitations of the target being outside the vue app. In any case, I can't find any mention of a caveat with regards to using both
target-el
andv-if
in either the doc section showing v-if being used or the doc section for target-el.The text was updated successfully, but these errors were encountered: