Skip to content

๐Ÿ” Easy to drop or replace specified key in an array.

License

Notifications You must be signed in to change notification settings

QingWei-Li/vuea

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

4 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Vuea

Build Status npm

๐Ÿ” Easy to drop or replace specified key in an array.

Installation

npm i vuea -S

Usage

import Vue from 'vue'
import Vuea from 'vuea'

Vue.use(Vuea)

new Vue({
  data () {
    return { arr: ['a', 'b', 'c'] }
  },

  created () {
    this.$drop(this.arr, 'b') // return 'b', vm.arr equal ['a', 'c']
    this.$replace(this.arr, 'a', 'd') // return 'a', vm.arr equal ['d', 'c']
  }
})
import { drop, replace } from 'vuea'

const arr = ['a', 'b', 'c']

drop(arr, 'b') // ['a', 'c']
replace(arr, 'a', 'd') // ['d', 'c']

License

MIT

About

๐Ÿ” Easy to drop or replace specified key in an array.

Resources

License

Stars

Watchers

Forks

Packages

No packages published