1 min readApr 3, 2018
I don’t understand why people hate $options
. Using created
hook for that is much worse than passing to data
.
To be honest, it’s a problem of Vue and its templates. In React, you can just define constants anywhere and use it inside JSX. Also, React uses setState
instead of getters/setters and doesn’t wrap state.