Press n or j to go to the next uncovered block, b, p or k for the previous block.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 | 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 35x 35x 35x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x 50x | import ApolloClient from 'apollo-client'; import { InMemoryCache } from 'apollo-cache-inmemory'; import createCommerceToolsLink from './helpers/createCommerceToolsLink'; import getProduct from './api/getProduct'; import getCategory from './api/getCategory'; import createCart from './api/createCart'; import updateCart from './api/updateCart'; import getCart from './api/getCart'; import addToCart from './api/addToCart'; import removeFromCart from './api/removeFromCart'; import updateCartQuantity from './api/updateCartQuantity'; import getMe from './api/getMe'; import createMyOrderFromCart from './api/createMyOrderFromCart'; import getShippingMethods from './api/getShippingMethods'; import updateShippingDetails from './api/updateShippingDetails'; import customerSignMeUp from './api/customerSignMeUp'; import customerSignMeIn from './api/customerSignMeIn'; import customerSignOut from './api/customerSignOut'; import getOrders from './api/getMyOrders'; import applyCartCoupon from './api/applyCartCoupon'; import removeCartCoupon from './api/removeCartCoupon'; import customerChangeMyPassword from './api/customerChangeMyPassword'; import customerUpdateMe from './api/customerUpdateMe'; import createAccessToken from './helpers/createAccessToken'; import { apiClientFactory } from '@vue-storefront/core'; import { Config, ConfigurableConfig } from './types/setup'; let apolloClient: ApolloClient<any> = null; const onSetup = (config: Config) => { config.languageMap = config.languageMap || {}; config.acceptLanguage = config.languageMap[config.locale] || config.acceptLanguage; apolloClient = new ApolloClient({ link: createCommerceToolsLink(), cache: new InMemoryCache(), ...config.customOptions }); }; const { setup, update, getSettings } = apiClientFactory<Config, ConfigurableConfig>({ onSetup, defaultSettings: { locale: 'en', acceptLanguage: ['en'], cookies: { currencyCookieName: 'vsf-currency', countryCookieName: 'vsf-country', localeCookieName: 'vsf-locale' } } }); export { getSettings, createAccessToken, apolloClient, setup, update, getProduct, getCategory, getOrders, createCart, updateCart, getCart, addToCart, removeFromCart, getMe, updateCartQuantity, createMyOrderFromCart, getShippingMethods, updateShippingDetails, customerSignMeUp, customerSignMeIn, customerSignOut, applyCartCoupon, removeCartCoupon, customerChangeMyPassword, customerUpdateMe }; export * from './types/Api'; export * from './types/GraphQL'; export * from './types/setup'; export * from './helpers/token'; export * as cartActions from './helpers/cart/actions'; |