@jetshop/core 6.2.0-alpha.d3139588 → 6.2.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -88,7 +88,7 @@ const wrapTree = (tree, req, renderOptions, client, channelHandler, authHandler,
88
88
  statusCode: routerContext.statusCode,
89
89
  helmet: helmetContext.helmet,
90
90
  apolloState,
91
- polyfill: createPolyfill(locale)
91
+ polyfill: createPolyfill(locale, config.usePolyfilling)
92
92
  };
93
93
  });
94
94
  const startResponse = ({ res, head, statusCode }) => {
@@ -104,7 +104,7 @@ const persistedQueryClients = {};
104
104
  const createRenderer = (template, tree, options) => {
105
105
  return (req, res) => __awaiter(void 0, void 0, void 0, function* () {
106
106
  var _a;
107
- const { apolloConfig, loadableStatsPath, intl, schema, globalClient, disableGeoRedirect, singleDomainMode } = options;
107
+ const { apolloConfig, loadableStatsPath, intl, schema, globalClient, disableGeoRedirect, singleDomainMode, usePolyfilling = false } = options;
108
108
  // Set response headers immediately
109
109
  res.setHeader('Content-Type', 'text/html');
110
110
  const fullUrl = req.protocol + '://' + req.get('host') + req.originalUrl;
@@ -195,7 +195,8 @@ const createRenderer = (template, tree, options) => {
195
195
  });
196
196
  const { wrappedTree, routerUrl, statusCode, helmet: { htmlAttributes, title, meta, style, link }, apolloState, polyfill } = yield wrapTree(tree, req, options, client, channelHandler, authHandler, previewHandler, translator, locale, {
197
197
  loginPath: options.loginPath,
198
- pathsWithNoAuthRequired: options.pathsWithNoAuthRequired
198
+ pathsWithNoAuthRequired: options.pathsWithNoAuthRequired,
199
+ usePolyfilling
199
200
  }, chunkExtractor);
200
201
  if (routerUrl) {
201
202
  return res.redirect(
@@ -1 +1 @@
1
- {"version":3,"file":"createRenderer.js","sourceRoot":"","sources":["createRenderer.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,gCAAgC,EAAE,MAAM,2CAA2C,CAAC;AAC7F,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,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EAAE,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC;IAC7B,CAAC,CAAA,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
@@ -19,7 +19,6 @@ export function AddToCartFormik({ product, variant, commentValidators = {}, getM
19
19
  onAddToCartInit, onAddToCartError, onAddToCartSuccess, cartMutation,
20
20
  // Backwards compatability with render props
21
21
  children }) {
22
- // tslint:disable-next-line:no-unused
23
22
  const [addToCartMutation] = useMutation(cartMutation, {
24
23
  onCompleted: () => localStorage.setItem('cartChange', '1')
25
24
  });
@@ -1 +1 @@
1
- {"version":3,"file":"AddToCartFormik.js","sourceRoot":"","sources":["AddToCartFormik.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAmB,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAe,MAAM,QAAQ,CAAC;AAWrD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,kBAAkB,EACnB,MAAM,iDAAiD,CAAC;AACzD,OAAO,QAAQ,MAAM,gCAAgC,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AA6C7D,MAAM,UAAU,eAAe,CAAC,EAC9B,OAAO,EACP,OAAO,EACP,iBAAiB,GAAG,EAAE,EACtB,iBAAiB,EACjB,aAAa;AACb,wBAAwB;AACxB,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EAClB,YAAY;AACZ,4CAA4C;AAC5C,QAAQ,EACa;IACrB,qCAAqC;IACrC,MAAM,CAAC,iBAAiB,CAAC,GAAG,WAAW,CAGrC,YAAY,EAAE;QACd,WAAW,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC,OAAO,CAAC,YAAY,EAAE,GAAG,CAAC;KAC3D,CAAC,CAAC;IAEH,MAAM,EAAE,MAAM,EAAE,SAAS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OAAO,EAAE,UAAU,CAAC,OAAO;gBAC3B,KAAK,EAAE,UAAU,CAAC,KAAK;gBACvB,QAAQ,EAAE,KAAK,CAAC,QAAQ;gBACxB,iBAAiB,EAAE,OAAO;gBAC1B,UAAU;aACX,CAAC;YAEF,IAAI,eAAe,EAAE;gBACnB,eAAe,CAAC,eAAe,CAAC,CAAC;aAClC;YAED,OAAO,iBAAiB,CAAC;gBACvB,SAAS,EAAE;oBACT,KAAK;iBACN;gBACD,MAAM,EAAE,CAAC,KAAK,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE;oBAC1B,KAAK,CAAC,MAAM,CAAC;wBACX,MAAM,EAAE;4BACN,IAAI;;gCACF,OAAO,MAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,SAAS,0CAAE,IAAI,CAAC;4BAC/B,CAAC;yBACF;qBACF,CAAC,CAAC;gBACL,CAAC;aACF,CAAC;iBACC,IAAI,CACH,gBAAgB,CAAC;gBACf,kBAAkB;gBAClB,eAAe;gBACf,MAAM;gBACN,SAAS;aACV,CAAC,CACH;iBACA,KAAK,CACJ,cAAc,CAAC;gBACb,gBAAgB;gBAChB,eAAe;aAChB,CAAC,CACH,CAAC;QACN,CAAC;KAAA;IAED,MAAM,EAAE,IAAI,EAAE,GAAG,YAAY,CAAC;QAC5B,OAAO;QACP,OAAO;QACP,iBAAiB;QACjB,iBAAiB;QACjB,aAAa;QACb,MAAM;KACP,CAAC,CAAC;IAEH,OAAO,oBAAC,cAAc,IAAC,KAAK,EAAE,IAAI,IAAG,QAAQ,CAAC,IAAI,CAAC,CAAkB,CAAC;AACxE,CAAC;AAED,eAAe,eAAe,CAAC"}
@@ -17,7 +17,7 @@ const AuthProvider = function AuthProvider(props) {
17
17
  const client = useApolloClient();
18
18
  const { setCartId } = useCartId();
19
19
  const { selectedChannel } = useContext(ChannelContext);
20
- const { pathsWithNoAuthRequired, loginPath } = useShopConfig();
20
+ const { pathsWithNoAuthRequired, loginPath, useIndefinitelySavedCart = false } = useShopConfig();
21
21
  const location = useLocation();
22
22
  const history = useHistory();
23
23
  const track = useTracker();
@@ -56,19 +56,30 @@ const AuthProvider = function AuthProvider(props) {
56
56
  }
57
57
  props.auth.setAuthToken(token);
58
58
  localStorage.setItem('loggedIn', '1');
59
- customerId && setCartId(String(customerId));
59
+ if (useIndefinitelySavedCart) {
60
+ customerId && setCartId(String(customerId));
61
+ }
60
62
  }
61
63
  else {
62
64
  props.auth.clearAuthToken();
63
65
  localStorage.removeItem('loggedIn');
64
- setCartId(null);
66
+ if (useIndefinitelySavedCart) {
67
+ setCartId(null);
68
+ }
65
69
  }
66
70
  client
67
71
  .resetStore()
68
72
  .then(() => setLoggedIn(loggedIn))
69
73
  .catch(() => setLoggedIn(loggedIn));
70
74
  }
71
- }), [client, loggedIn, props.auth, selectedChannel.requiresAuth, setCartId]);
75
+ }), [
76
+ client,
77
+ loggedIn,
78
+ props.auth,
79
+ selectedChannel.requiresAuth,
80
+ setCartId,
81
+ useIndefinitelySavedCart
82
+ ]);
72
83
  return React.createElement(AuthContext.Provider, Object.assign({ value: value }, props));
73
84
  };
74
85
  function useLocalStorageLoggedIn(setLoggedIn) {
@@ -1 +1 @@
1
- {"version":3,"file":"AuthProvider.js","sourceRoot":"","sources":["AuthProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAErD,OAAO,WAAW,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,cAAc,MAAM,yCAAyC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,E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,CAAC,YAAY,CAAC,CAAC"}
@@ -83,6 +83,9 @@ export interface BootOptions {
83
83
  server?: Server;
84
84
  usePrimaryRouteForProducts?: boolean;
85
85
  useTrackingConsentAPI?: boolean;
86
+ useIndefinitelySavedCart?: boolean;
87
+ /** Enable this if you want to use Polyfill.io service before booting shop on client */
88
+ usePolyfilling?: boolean;
86
89
  }
87
90
  interface Sentry {
88
91
  /** DSN used to track client side errors */
@@ -1 +1 @@
1
- {"version":3,"file":"ConfigProvider.js","sourceRoot":"","sources":["ConfigProvider.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,EAAE,EAAE,aAAa,EAAgB,MAAM,OAAO,CAAC;AAM3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAsG5D,MAAM,CAAC,MAAM,iBAAiB,GAAG,aAAa,CAC5C,SAAS,CACV,CAAC;AAEF,MAAM,UAAU,cAAc,CAAC,EAO9B;QAP8B,EAC7B,MAAM,EAAE,UAAU,EAClB,QAAQ,OAKT,EAJI,IAAI,cAHsB,sBAI9B,CADQ;IAKP,MAAM,MAAM,GAAG,gBAAgB,CAAC,UAAU,CAAC,CAAC;IAC5C,OAAO,CACL,oBAAC,iBAAiB,CAAC,QAAQ,kBAAC,KAAK,EAAE,MAAM,IAAM,IAAI,GAChD,QAAQ,CACkB,CAC9B,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"ConfigProvider.js","sourceRoot":"","sources":["ConfigProvider.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,EAAE,EAAE,aAAa,EAAgB,MAAM,OAAO,CAAC;AAM3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAyG5D,MAAM,CAAC,MAAM,iBAAiB,GAAG,aAAa,CAC5C,SAAS,CACV,CAAC;AAEF,MAAM,UAAU,cAAc,CAAC,EAO9B;QAP8B,EAC7B,MAAM,EAAE,UAAU,EAClB,QAAQ,OAKT,EAJI,IAAI,cAHsB,sBAI9B,CADQ;IAKP,MAAM,MAAM,GAAG,gBAAgB,CAAC,UAAU,CAAC,CAAC;IAC5C,OAAO,CACL,oBAAC,iBAAiB,CAAC,QAAQ,kBAAC,KAAK,EAAE,MAAM,IAAM,IAAI,GAChD,QAAQ,CACkB,CAC9B,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jetshop/core",
3
- "version": "6.2.0-alpha.d3139588",
3
+ "version": "6.2.0",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "**/*.js",
package/polyfills.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const createPolyfill: (locale: string) => string;
1
+ export declare const createPolyfill: (locale: string, usePolyfilling: boolean) => string;
package/polyfills.js CHANGED
@@ -1,5 +1,5 @@
1
1
  const polyfills = (locale) => [
2
- 'es6',
2
+ 'es2015',
3
3
  'Object.values',
4
4
  'Object.entries',
5
5
  'Object.keys',
@@ -21,16 +21,31 @@ const polyfills = (locale) => [
21
21
  'Symbol',
22
22
  'ResizeObserver'
23
23
  ];
24
- export const createPolyfill = (locale) => {
24
+ export const createPolyfill = (locale, usePolyfilling) => {
25
25
  const features = polyfills(locale).join(',');
26
26
  // Here we add two script tags to be run once the client is loaded. One sets a global variable 'polyFillsLoaded' to false and adds a function bootShop which, when called will set 'polyFillsLoaded' to true. The second script will load the polyfills and once they are loaded will call the bootShop function to let the client know that the polyfills have been loaded and that the shop can be started.
27
27
  return `
28
28
  <script>
29
29
  window.polyFillsLoaded = false;
30
+
30
31
  window.bootShop = function() {
31
32
  window.polyFillsLoaded = true;
32
- };
33
+ };
34
+
35
+ // If polyfill.io does not respond, start the shop anyway
36
+ if (${usePolyfilling}) {
37
+ setTimeout(() => {
38
+ if(!window.polyFillsLoaded) {
39
+ window.bootShop();
40
+ }
41
+ }, 5000);
42
+ }
33
43
  </script>
34
- <script async defer src="https://cdn.polyfill.io/v3/polyfill${process.env.NODE_ENV === 'production' ? '.min' : ''}.js?callback=bootShop&features=${features}&flags=gated"></script>`;
44
+
45
+ ${usePolyfilling
46
+ ? `<script async defer src='https://polyfill-fastly.io/v3/polyfill${process.env.NODE_ENV === 'production' ? '.min' : ''}.js?callback=bootShop&features=${features}'></script>`
47
+ : '<script>window.bootShop();</script>'}
48
+
49
+ `;
35
50
  };
36
51
  //# sourceMappingURL=polyfills.js.map
package/polyfills.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"polyfills.js","sourceRoot":"","sources":["polyfills.ts"],"names":[],"mappings":"AAAA,MAAM,SAAS,GAAG,CAAC,MAAc,EAAE,EAAE,CAAC;IACpC,KAAK;IACL,eAAe;IACf,gBAAgB;IAChB,aAAa;IACb,eAAe;IACf,sBAAsB;IACtB,2BAA2B;IAC3B,yBAAyB;IACzB,0BAA0B;IAC1B,sBAAsB;IACtB,YAAY;IACZ,sBAAsB;IACtB,2BAA2B;IAC3B,6BAA6B;IAC7B,KAAK;IACL,sBAAsB;IACtB,gBAAgB,MAAM,EAAE;IACxB,SAAS;IACT,OAAO;IACP,QAAQ;IACR,gBAAgB;CACjB,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,MAAc,EAAE,EAAE;IAC/C,MAAM,QAAQ,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC7C,6YAA6Y;IAC7Y,OAAO;;;;;;;gEAQL,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EACnD,kCAAkC,QAAQ,yBAAyB,CAAC;AACtE,CAAC,CAAC"}
1
+ {"version":3,"file":"polyfills.js","sourceRoot":"","sources":["polyfills.ts"],"names":[],"mappings":"AAAA,MAAM,SAAS,GAAG,CAAC,MAAc,EAAE,EAAE,CAAC;IACpC,QAAQ;IACR,eAAe;IACf,gBAAgB;IAChB,aAAa;IACb,eAAe;IACf,sBAAsB;IACtB,2BAA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