尽大可能的简化vuex的调用和执行过程

    1. <input :value="message" @input="updateMessage">
    1. computed: {
    2. ...mapState({
    3. message: state => state.obj.message
    4. })
    5. },
    6. methods: {
    7. updateMessage (e) {
    8. this.$store.commit('updateMessage', e.target.value)
    9. }
    10. }
    1. mutations: {
    2. updateMessage (state, message) {
    3. state.obj.message = message
    4. }
    5. }