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

Function genSlot

static/vuejs/vue.esm.js:8805–8821  ·  view source on GitHub ↗
(el)

Source from the content-addressed store, hash-verified

8803}
8804
8805function genSlot (el) {
8806 var slotName = el.slotName || '"default"';
8807 var children = genChildren(el);
8808 var res = "_t(" + slotName + (children ? ("," + children) : '');
8809 var attrs = el.attrs && ("{" + (el.attrs.map(function (a) { return ((camelize(a.name)) + ":" + (a.value)); }).join(',')) + "}");
8810 var bind$$1 = el.attrsMap['v-bind'];
8811 if ((attrs || bind$$1) && !children) {
8812 res += ",null";
8813 }
8814 if (attrs) {
8815 res += "," + attrs;
8816 }
8817 if (bind$$1) {
8818 res += (attrs ? '' : ',null') + "," + bind$$1;
8819 }
8820 return res + ')'
8821}
8822
8823// componentName is el.component, take it as argument to shun flow's pessimistic refinement
8824function genComponent (componentName, el) {

Callers 1

genElementFunction · 0.70

Calls 1

genChildrenFunction · 0.70

Tested by

no test coverage detected