Last active
February 23, 2023 05:38
-
-
Save wangziling/bf5359c5a252cfd47bc60855f4794459 to your computer and use it in GitHub Desktop.
Teleport variables.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default { | |
name: "TeleportVariable", | |
inheritAttrs: false, // Must set as `false`. Or you will see your bindings existed on your slot DOM attributes, as data="[object Object]" | |
render () { | |
return this.$scopedSlots.default(this.$attrs); | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Can use as below:
Demo: https://codesandbox.io/s/hungry-johnson-hveo4