官术网_书友最值得收藏!

Vuex

Vuex provides a powerful way to manage the data of an application as the complexity of the UI increases, by centralizing the application's data into a single store.

We can get snapshots of the application's state by inspecting the store in Vue Devtools:

Figure 1.2. Vue Devtools Vuex tab

The left column tracks changes made to the application data. For example, say the user saves or unsaves an item. You might name this eventtoggleSaved. Vue Devtools lets you see the particulars of this event as it occurs.

We can also revert to any previous state of the data without having to touch the code or reload the page. This function, calledTime Travel Debugging, is something you'll find very useful for debugging complex UIs.

主站蜘蛛池模板: 萝北县| 通化县| 高清| 桐乡市| 德化县| 花莲县| 达州市| 奉新县| 巴青县| 新宁县| 翁牛特旗| 襄垣县| 珠海市| 巨鹿县| 竹溪县| 龙江县| 鱼台县| 临夏市| 鲜城| 敦化市| 宜昌市| 濮阳县| 疏附县| 安岳县| 社会| 杭锦旗| 乌拉特中旗| 繁昌县| 莆田市| 防城港市| 金塔县| 华坪县| 仁怀市| 炉霍县| 金乡县| 手机| 德庆县| 华安县| 保康县| 青田县| 深泽县|