MCPcopy Create free account
hub / github.com/TruthHun/BookStack / renderStatic

Function renderStatic

static/vuejs/vue.runtime.common.js:3501–3518  ·  view source on GitHub ↗

* Runtime helper for rendering static trees.

(
  index,
  isInFor
)

Source from the content-addressed store, hash-verified

3499 * Runtime helper for rendering static trees.
3500 */
3501function renderStatic (
3502 index,
3503 isInFor
3504) {
3505 var tree = this._staticTrees[index];
3506 // if has already-rendered static tree and not inside v-for,
3507 // we can reuse the same tree by doing a shallow clone.
3508 if (tree && !isInFor) {
3509 return Array.isArray(tree)
3510 ? cloneVNodes(tree)
3511 : cloneVNode(tree)
3512 }
3513 // otherwise, render a fresh tree.
3514 tree = this._staticTrees[index] =
3515 this.$options.staticRenderFns[index].call(this._renderProxy);
3516 markStatic(tree, ("__static__" + index), false);
3517 return tree
3518}
3519
3520/**
3521 * Runtime helper for v-once.

Callers

nothing calls this directly

Calls 3

cloneVNodesFunction · 0.70
cloneVNodeFunction · 0.70
markStaticFunction · 0.70

Tested by

no test coverage detected