Introduction
Communication between “neighboring” components can be achieved in several ways, and the choice of one of the offered mechanisms usually depends on the complexity of the application.
a) Communication via common parent ($emit -> $on & attribute -> props )
A feasible solution, but it is generally a bad idea, because it is difficult to monitor the flow of data and therefore difficult to debug.
b) Event bus ($emit & $on)
A fast and simple solution for applications with a simple architecture and fewer components.
c) Pinia / Vuex (centralized state)
For Vue 3 use Pinia (official store). Vuex remains relevant for older Vue 2 apps.




