售 价:¥
温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印
为你推荐
Title Page
Copyright and Credits
Vuex Quick Start Guide
Packt Upsell
Why subscribe?
PacktPub.com
Contributors
About the author
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Download the color images
Code in Action
Conventions used
Get in touch
Reviews
Rethinking User Interfaces with Flux, Vue, and Vuex
MVC problems and the Flux solution
What is Vuex?
Understanding the Flux fundamentals
Actions
Dispatcher
Stores
Views
Rendering data in the stores
Stores and private components model
Summarizing Flux architecture
Benefits of using Flux
Summary
Implementing Flux Architecture with Vuex
Technical requirements
Vuex at a glance
Boilerplate code for the examples
Vue.js reactivity system explained
Understanding the core concepts of Vuex
Understanding the Vuex store
Accessing the single state tree inside components
The mapState helper
Components' local state
Computing a derived state with getters
The mapGetters helper
Changing the application state with mutations
Commiting a mutation
Enumerating mutation types using constant strings
Mutations must be synchronous
The mapMutations helper
Committing mutations within actions
Action declaration
Dispatching an action
The mapActions helper
Using modules for better scalability
Module local state
Module with namespace
Dynamic module registration
Module reuse
Enabling strict mode while developing
Form handling restrictions when using Vuex
A simple counter example
Summary
Setting Up Development and Test Environment
Technical requirements
Setting up the development environment
Using npm to prepare the project for Vue/Vuex
Using vue-loader for single-file components
Configuring the test environment
Summary
Coding the EveryNote App Using Vuex State Management
Technical requirements
Designing the EveryNote web app
Application structure
Developing the EveryNote app
Using a to-do list to help the development process
Displaying a list of notes
Creating new notes
Deleting existing notes
Updating existing notes
Other features
Recap and some considerations
Synchronizing with a remote server
Summary
Debugging Vuex Applications
Using vue-devtools
Component inspector
Events inspector
Vuex time travel
Enabling the Vuex built-in logger plugin
Summary
Using the Vuex Plugin System
Technical requirements
Understanding the Vuex plugin system
Empowering EveryNote with two plugins
Saving the app state with vuex-persistedstate
Synchronizing router data with vuex-router-sync
Developing a Google Analytics plugin
Developing an undo/redo plugin
Dealing with asynchronicity using promises
Chaining promises
Parallel execution of promises
Common mistakes when using promises
Summary
Other Books You May Enjoy
Leave a review - let other readers know what you think
买过这本书的人还买过
读了这本书的人还在读
同类图书排行榜