@banez/vue-array-store

Simple array store for Vue 3.
1,719
Install
npm install @banez/vue-array-store
Latest Version:1.2.0
Vue:3
License:MIT
Last Updated:Mar 18, 2023
Links: GitHub  ·  npm
Maintainer: banez

Simple Vue 3 array store

Vuex is very complicated to setup with TypeScript and required a lot of coding for simple stuff. Because of this I've created a simple array store which uses ref API from Vue 3.

Getting started

There is only 1 entry point for this package and it is called createArrayStore as shown in example bellow:

import type { StoreItem } from '@banez/vue-array-store';

interface Todo extends StoreItem {
  task: string;
}

const store = createArrayStore<Todo>();

store.set({
  id: '1',
  task: 'Hello world!',
});

console.log(store.items());

Example

You will be able to find an example on how to use this package with Vue App by cloning the GitHub repository or by exploring the code on the GitHub repository itself.

Related Packages

vuex-pathify

Ridiculously simple Vuex setup + wiring

322,817 1,358
nuxt3-vuex-module

Vuex support for Nuxt 3

165,911 26
nuxt-spa-store-init

A simple Nuxt module that will hydrate the VueX store when running in SPA mode (...

4,282 14
vue-store

Some simple utilities for Vue.

7,296
vue-cli-plugin-store

Vue CLI plugin for vuex

5,847

Version History

Version Released Vue License
1.2.0 >=3.2.25 MIT
1.1.0 >=3.2.25 MIT
1.0.0 >=3.2.25 MIT