Pārlūkot izejas kodu

include events methods in api reference

Evan You 8 gadi atpakaļ
vecāks
revīzija
6cddee4bf8
2 mainītis faili ar 11 papildinājumiem un 1 dzēšanām
  1. 1 1
      docs/en/SUMMARY.md
  2. 10 0
      docs/en/api.md

+ 1 - 1
docs/en/SUMMARY.md

@@ -11,7 +11,7 @@
   - [Actions](actions.md)
 - [Data Flow](data-flow.md)
 - [Application Structure](structure.md)
-- [Plugins](middlewares.md)
+- [Plugins](plugins.md)
 - [Strict Mode](strict.md)
 - [Form Handling](forms.md)
 - [Testing](testing.md)

+ 10 - 0
docs/en/api.md

@@ -101,3 +101,13 @@ const store = new Vuex.Store({ ...options })
 - **hotUpdate(newOptions: Object)**
 
   Hot swap new actions and mutations. [Details](hot-reload.md)
+
+- **on(event: String, cb: Function)**
+
+- **once(event: String, cb: Function)**
+
+- **off([event: String, cb: Function])**
+
+- **emit(event: String, ...args)**
+
+  Same event interface as found on a Vue instance. The only event the store emits is `mutation` (see [Plugins](plugins.md)).