I'm a full-stack Software Engineer and Architect. I specialise in front-end niceness, but my daily tasks are mostly about making server less work well and scale within our suit of micro services!
The new composition API is actually more difficult to understand. Vue2 was very declarative with the options API. Iβm not sure what advantages this brings? Itβs not like you have to include all options...
Moreover, this seems like overkill to fix the mixin problem? Sounds like they just got hook envy....
This post was more to show the new syntax, not the benefits of the composition API. Hence, my example is actually really bad from that stand point. Composition API shines once you have (with options API) related logic spread across different options (data, computed, methods, mounted, destroy, etc.). Composition API let's you group this logic together. It's not going to be an all-in replacement for Vue 2's options API. I can see people continue using it.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
The new composition API is actually more difficult to understand. Vue2 was very declarative with the options API. Iβm not sure what advantages this brings? Itβs not like you have to include all options...
Moreover, this seems like overkill to fix the mixin problem? Sounds like they just got hook envy....
This post was more to show the new syntax, not the benefits of the composition API. Hence, my example is actually really bad from that stand point. Composition API shines once you have (with options API) related logic spread across different options (data, computed, methods, mounted, destroy, etc.). Composition API let's you group this logic together. It's not going to be an all-in replacement for Vue 2's options API. I can see people continue using it.