UNPKG

873 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3exports.feature = exports.defaultPerformanceStore = void 0;
4var actions_1 = require("@shopify/app-bridge/actions");
5exports.defaultPerformanceStore = null;
6function reducer(state) {
7 if (state === void 0) { state = exports.defaultPerformanceStore; }
8 return state;
9}
10/**
11 * An object containing the key, actions, initial state and reducer of the Performance feature
12 * Can be used with the `withFeature` decorator to add the reducer
13 * and then make its actions and store available to the wrapped component
14 * @public
15 * */
16exports.feature = {
17 actions: {
18 skeletonPageLoad: actions_1.Performance.skeletonPageLoad,
19 fullPageLoad: actions_1.Performance.fullPageLoad,
20 },
21 key: 'performance',
22 initialState: exports.defaultPerformanceStore,
23 reducer: reducer,
24};