A
A
Alexander2018-08-02 19:04:53
Vue.js
Alexander, 2018-08-02 19:04:53

How to pass data from an application instance to a router component?

There is a simple SPA application with a router.

Right now I am passing data to the router component Indexfrom the Vue object via this.$parent, but I was told that this is an anti-pattern. How then is it correct to pass parameters from the main application to the router component?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Belyaev, 2018-08-02
@zkelo

https://ru.vuejs.org/v2/guide/components.html#%D0%...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question