Motivation
Simplify conditional templates
Example
html`
<div v-if=${isEmpty} class="placeholder">${this.placeholder}</div>
<div v-else-if=${!this.multiple} class="value">${currentLabels}</div>
<dy-scroll-box v-else class="values">
${typeof currentLabels?.at(0) === 'object' ? currentLabels : currentLabels?.join(', ')}
</dy-scroll-box>
`
How
Implemented in the _clone method of TemplateInstance
Current Behavior
Desired Behavior
References
Motivation
Simplify conditional templates
Example
How
Implemented in the
_clonemethod ofTemplateInstanceCurrent Behavior
Desired Behavior
References