Last active
May 14, 2023 14:52
-
-
Save aneurysmjs/9579916695a1e854beb41de5dcd35072 to your computer and use it in GitHub Desktop.
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
/** | |
<template> | |
<div id="foo" @click="handleClick">Yo!</div> | |
</template> | |
*/ | |
import { | |
createElementVNode as _createElementVNode, | |
openBlock as _openBlock, | |
createElementBlock as _createElementBlock, | |
} from "vue" | |
const _hoisted_1 = ["onClick"] | |
export function render(_ctx, _cache, $props, $setup, $data, $options) { | |
// this looks like verbose for the code you can write yourself | |
// because the compiler always is prioritizing to be more optimized, | |
// to be more explicit. so you have to actually pass null and all that, this | |
// is because we want the function calls to have the same amount of arguments so | |
// it can be more efficient. But in the user exposed `h` function, there's are a lot | |
// of convenience that provides that we can easier and fluent mirrowing the api | |
// ourself | |
return (_openBlock(), _createElementBlock("div", null, [ | |
_createElementVNode("div", { | |
id: "foo", | |
onClick: _ctx.handleClick | |
}, "Yo!", 8 /* PROPS */, _hoisted_1) | |
])) | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment