I agree with you, but the idea of this post was to put focus on the functional way of doing things.
The template you've provided would do fine in the simple example described in this post since we are only changing the inner text of the element. Each area of the template based on the user role could have a different number of child components and in that case things would be a lot more complicated.
I've been working with Vue and Node for a couple of years, mainly on internal tools for e-commerce businesses. Interested in Vue, Web Components, Dart, GraphQL, and WebXR.
You are right :) There are definitely cases where render functions are much better. I just didn't want new readers to think that Vue templates couldn't do this.
I agree with you, but the idea of this post was to put focus on the functional way of doing things.
The template you've provided would do fine in the simple example described in this post since we are only changing the inner text of the element. Each area of the template based on the user role could have a different number of child components and in that case things would be a lot more complicated.
You are right :) There are definitely cases where render functions are much better. I just didn't want new readers to think that Vue templates couldn't do this.
...it would be a lot more complicated even with jsx.