Render function vs expose #7531
Replies: 2 comments 3 replies
-
I don't think this is a As you can see from the following example, the value of
|
Beta Was this translation helpful? Give feedback.
-
This is working as intended. Returning a render function from setup and mixing that with options API is not a good combo, you will not be able to access anything from within setup in the Options API code, so just - don't do that. Chose one API (per component, at least) |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
https://vuejs.org/api/composition-api-setup.html#basic-usage
According to basic usage, I can expose local variables by returning them from the setup function.
https://vuejs.org/api/composition-api-setup.html#usage-with-render-functions
But then we get into render functions. Exposing the same does not work.
Should I file a bug report? This seems counter intuitive. What problem is expose supposed to solve if not the kind similar to that expressed here?
Beta Was this translation helpful? Give feedback.
All reactions