Thanks for sharing. I know is just to make the comparison, but I would strongly suggest against the usage of class inheritance and mixins. I know we usually think that using the features of a language is for the best, but in JS inheritance doesn't work as we are used to from other languages.
I think it is best to create small components and reuse them instead, as you show in the last example.
PS: The StackBlizt link is broken. :/
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.
Thanks for sharing. I know is just to make the comparison, but I would strongly suggest against the usage of class inheritance and mixins. I know we usually think that using the features of a language is for the best, but in JS inheritance doesn't work as we are used to from other languages.
I think it is best to create small components and reuse them instead, as you show in the last example.
PS: The StackBlizt link is broken. :/