MyGit

v4.0.0-beta.1

vuejs/vuex

版本发布时间: 2020-04-25 14:59:09

vuejs/vuex最新发布版本:v4.0.2(2021-06-17 23:52:07)

Features

Breaking Changes

Bundles are now aligned with Vue 3

The bundles are generated as below to align with Vue 3 bundles.

Typings for ComponentCustomProperties

Vuex 4 removes its global typings for this.$store within Vue Component due to solving issue #994. When using TypeScript, you must provide your own augment declaration.

Please place the following code in your project to have this.$store working.

// vuex-shim.d.ts

declare module "@vue/runtime-core" {
  // Declare your own store states.
  interface State {
    count: number
  }

  interface ComponentCustomProperties {
    $store: Store<State>;
  }
}

相关地址:原始地址 下载(tar) 下载(zip)

查看:2020-04-25发行的版本