I work with a simple store (see code). And it works very well. So I can change data in a RouterView and it will be changed immediately in a Navigation Component. It sounds like an observer pattern to me, doesn't it?
// store.js
import { reactive } from 'vue'
export const store = reactive({
gender: "",
name: "",
});
Question: But I would like to know how it works and how the same would look like in Vanilla JS.