I am trying to reproduce your solution and a question has come up. my goal is to pass data torouter-view, I am now passing as props, but I do not know if it is the best solution?
On each page I have a variable corresponding to the page that will work this data.
Whoooa, good solution.
I am trying to reproduce your solution and a question has come up. my goal is to pass
data
torouter-view
, I am now passing asprops
, but I do not know if it is the best solution?On each page I have a variable corresponding to the page that will work this
data
.Do you have any suggestions?
Passing props to
<router-view>
is fine in my opinion!ty :p
a problem occured. On some pages, the props
data
is expected to be an object, but on others it is an array.I thought I'd give the property multiple types, or is there a better solution?
Solution
LGTM ;)