It is not an event bus, it is not Vuex and it is not Pina. It is an example of how I would use vue's inject and provider. Excellent for managing an almost decentralized state. I invite you to explore the CountProvider, App, EntryEditor and MyJournal files. With CounterProvider we develop a wrapper component that provides us with a controlled state.
TypeScript cannot handle type information for .vue
imports by default, so we replace the tsc
CLI with vue-tsc
for type checking. In editors, we need Volar to make the TypeScript language service aware of .vue
types.
See Vite Configuration Reference.
npm install
npm run dev
npm run build
Lint with ESLint
npm run lint