Abstract
Components are great for reusing an entire custom element, but we can’t use just a portion of the component. To share functionality among multiple components, we have to use mixins. Custom directives will allow us to build out functionality that we can apply to standard HTML components and custom Vue.js components. The render function will give us more control over how our template is built, giving us the ability to use logic in JavaScript to build our templates.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2018 Brett Nelson
About this chapter
Cite this chapter
Nelson, B. (2018). Reusable Code. In: Getting to Know Vue.js. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-3781-6_9
Download citation
DOI: https://doi.org/10.1007/978-1-4842-3781-6_9
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-3780-9
Online ISBN: 978-1-4842-3781-6
eBook Packages: Professional and Applied ComputingProfessional and Applied Computing (R0)Apress Access Books