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

Function genSlot

static/vuejs/vue.js:8801–8817  ·  view source on GitHub ↗
(el)

Source from the content-addressed store, hash-verified

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

Callers 1

genElementFunction · 0.70

Calls 1

genChildrenFunction · 0.70

Tested by

no test coverage detected