Skip to content

Releases: SalesforceCommerceCloud/pwa-kit

v2.3.0

27 Oct 22:09
e6b8325

Choose a tag to compare

Featured Change: React Query Support 🎉

The pwa-kit-react-sdk now supports data fetching with React Query on the server side.

For details on how to migrate a v2.2 project to v2.3, see the Upgrade to v2.3 guide.

Changes

Full changelog: v2.2.0...v2.3.0

pwa-kit-react-sdk

  • Support react-query server-side data fetching. #724
  • Add a server-safe default configuration for queryClientConfig option. #734
  • Add useServerContext hook with the res response object and the isServerSide flag. #737
  • Handle react-query server-side errors. #735
  • Fix internal build script. #706
  • Add Correlation ID to SCAPI requests. #728

template-retail-react-app

  • Fix locale alias by including locale object inside the MultiSite Context. #716
  • Updated translations. #725
  • Add new Einstein API activities. #714
  • Fix search field to recognize the & character. #736
  • Fix filters on search results page. #742
  • Make copyright date in footer dynamic. #741
  • Bugfix: image gallery thumbnails not working without DIS. #786

pwa-kit-create-app

  • Fix missing required fields in the manifest.json file for generated projects. #729
  • Update ODS instance URL for the retail-react-app-demo preset. #799

pwa-kit-runtime

  • Performance: Skip retries when flushing CloudWatch metrics and prioritize returning a response instead. #720
  • Add correlation-id to the header of SCAPI requests. #728

pwa-kit-dev

  • Minimize "Module not found" errors during a webpack rebuild whenever a package dependency is being updated or built. #722
  • Update minimatch. #793

v2.2.0

26 Aug 23:33
a045d60

Choose a tag to compare

Changes

Full changelog: v2.1.0...v2.2.0

template-retail-react-app

  • Update zzrf-001 instance URL. #694
  • Optimize server-side performance. #667
  • Remove references to session bridging. #684

pwa-kit-dev

  • Added option to specify where the credentials can be saved to or read from. #647

New Contributors

v2.1.0

05 Jul 22:18
b3ac01f

Choose a tag to compare

Featured Change: Hot Reloading on Client Side 🔥

See your changes as soon as you make them! Hot reloading now works on the client side as well as the server side, thanks to hot module replacement.

A page reload is still required when:

  • Adding syntactically invalid changes.
  • Adding a new loadable page.
  • Updating a getProps function.

Changes

Full changelog: v2.0.0...v2.1.0

pwa-kit-dev

  • Replace Mobify references/links with proper PWA Kit values. #619
  • Add support for a custom build directory to pwa-kit-dev build. #628
  • Introduce client-side hot module replacement. #630

pwa-kit-react-sdk

  • Remove console logs from route component. #651

v2.0.0

17 May 02:24
cb136a8

Choose a tag to compare

What’s New

We’ve added lots of new features to PWA Kit v2, including:

  • 🥳 TypeScript support. The build tools now support TypeScript by default—without having to update the configuration files for Babel or Webpack.
  • 🧰 An updated development server that supports hot reloading on the server side and makes it possible to support hot reloading on the client side in a future release.
  • 🤓 An all-new command-line tool called pwa-kit-dev that bundles our recommended development tools like Webpack, Babel, and Jest to support zero-config project templates.
  • 🖌️ Experimental support for non-React apps for those users interested in using Managed Runtime to host other Express-based apps (not just the Retail React App).

See our Upgrade to v2 guide for details on how to migrate your v1 site to v2.

Changes

Full changelog: v1.5.2...v2.0.0

pwa-kit-create-app

  • Fix generator log #571
  • Fix incorrect site related values when generating without use of a preset #470
  • Support Multi-site implementation using dynamic config #469
  • Add verbose flag to generator #463
  • Environment Specific Configuration Support #477

pwa-kit-dev

  • Make the createApp API idiomatic for Express, fix service-worker loading. #536
  • Remove lodash and bluebird. #534
  • Allow pass thru cli options for test command #537
  • Ensure we copy the package.json file into the build folder. Also move logic for copying config files into the build script from the webpack config #524
  • Loading page: avoid seeing infinite reloads #532
  • Remove legacy remote proxy, which allowed remote environments to use proxy configs in package.json #425
  • Fix source maps cannot be found when debugging the server #526
  • Generate different reports for different bundles #508
  • Allow custom webpack config in projects #462
  • Hide webpack performance warnings #471
  • Support Multi-site implementation using dynamic config #469
  • Loading screen #473
  • Service worker loading for dev server #464
  • Environment Specific Configuration Support #477
  • Remove Webpack PwaKitConfigPlugin #443

pwa-kit-react-sdk

  • Remove lodash and bluebird. #534
  • Support Multi-site implementation using dynamic config #469
  • Support functions as default exports in the applications routes.jsx file. #447
  • Serialize application configuration in the HTML during rendering process. #447
  • Remove create-hash-manifest.js #425
  • Fix upload bug with extending an options object #419

pwa-kit-runtime

  • Make the createApp API idiomatic for Express, fix service-worker loading. #536
  • Add environment specific configuration support via getConfig. #447
  • Remove legacy remote proxy, which allowed remote environments to use proxy configs in package.json #425
  • Remove default body-parser middleware from express server. #444

Templates

template-retail-react-app

  • Multi-site, Fix the case when no site aliases is set #551
  • Fix invalid refresh token #528
  • Add valid token check before using refresh token on login #533
  • Fix localization scripts to output to the correct default locale #539
  • Merge guest cart and registered cart #540
  • Move retail react app jest setup out from pwa-kit-dev #545
  • Remove legacy remote proxy, which allowed remote environments to use proxy configs in package.json #425
  • Rename ‘pwa’ directory into ‘template-retail-react-app’ #485
  • Optimize visibility-off.svg #512
  • Support Multi-site implementation using dynamic config #469
  • Service worker loading for dev server #464
  • Environment Specific Configuration Support #477

template-express-minimal

template-typescript-minimal

v1.5.2

26 Apr 00:43
ed1c4fd

Choose a tag to compare

Changes

Full changelog: v1.5.1...v1.5.2

Bug Fixes

v1.5.1

07 Apr 21:15
9fd7850

Choose a tag to compare

v1.5.0

22 Mar 21:12
a1df0cb

Choose a tag to compare

Full changelog: v1.4.0...v1.5.0

Base SDK

Featured Change: Enhanced Configuration Management

The base SDK now allows configurations based on your environments. For details, see the documentation on Configuration Files.

Related PRs: #421, #442, #451, #453

Bug Fixes

  • Prevent accidental overwrite of default options in upload.js. #419
  • Fix the versioning of the SDK's peer dependencies. #432
  • Fix generator failing on Windows using WSL. #385

Other Changes

  • Enhancements to project generator questions. #374
  • Make enableBodyParser flag in createApp optional. #446
  • Remove unused packages (url-parse and enzyme-adapter-react-16 ). #411, #424

Retail React App

Featured Change: Multi-Site Management

With v1.5, PWA Kit includes a reference implementation of multi-site management. For details, see the Multiple Sites guide in our documentation.

Related PRs: #391, #382, #452, #438, #445

Bug Fixes

  • Fix for locale selector on Windows. #381
  • Clean up the test mock server. #439, #441
  • Add a fallback currency to the <ProductTile /> component. #450
  • Warn when using incompatible versions of Node. #384, #410
  • Fix the proxy config for a generated project. #454

Other Changes

  • Support storing authentication tokens in a cookie to enable hybrid storefronts with user flows between SFRA and PWA Kit. #429

Community Contributions

@stm-dschulz made their first contribution by adding a forgot password flow to the Retail React App 🎉. #373

v1.4.0

28 Jan 04:55
cf5ca6f

Choose a tag to compare

Featured Change: Project Creation Presets

You can now create a PWA Kit project using presets. Presets let you specify a template for your project files and (optionally) use preconfigured settings for connecting to a B2C Commerce instance.

To create a project using the Retail React App template and connect it to our demo sandbox, run the following command in your terminal:

npx pwa-kit-create-app --preset retail-react-app-demo

With this new demo preset, anyone can try out PWA Kit in minutes!

To create a project with a different preset or use custom settings for connecting to your own B2C Commerce instance, run npx pwa-kit-create-app and follow the prompts.

To learn about all the available options for creating a project, run npx pwa-kit-create-app --help.

PRs: #285, #325, #322, #357, #358, #361

Changes

Full changelog: v1.3.0...v1.4.0

Bug Fixes

  • Add constants for <meta theme-color|apple-mobile-web-app-title>. #287
  • Hide locale selector when there’s only a single locale. #262
  • Add to Cart remains active unless the item is out of stock. #222
  • Update error link. #303
  • Deprecate create-hash-manifest script. #300
  • Fix redirect after account creation. #360

Security Updates

  • Don’t send the HSTS header in local development. #288
  • [Snyk] Security upgrade shelljs from 0.8.4 to 0.8.5. #307
  • [Snyk] Security upgrade nanoid from 3.1.30 to 3.1.31. #308
  • [Snyk] Security upgrade cross-fetch from 3.1.4 to 3.1.5. #351

Other Changes

  • Support for React 17. #278
  • Support for NPM 7 & 8. #302
  • Update dependencies. #347, #346, #317
  • Reuse proxy connections in SDK. #306
  • Fix server error handling for unrecoverable errors. #326
  • Preliminary translations for the demo storefront. #324

v1.3.0

07 Jan 07:23
f73aff9

Choose a tag to compare

Changes

v1.2.0...v1.3.0

Bug Fixes

  • Promotion codes appear in uppercase in order summary. #224
  • Order summary prices on checkout page misaligned on mobile. #233
  • Shipping method description overflows the price section. #232
  • Stack trace data and SSR options are visible on error pages when viewing page source. #230 #249
  • Incorrect prop warning for section subtitle. #282
  • Incorrect repository URL in the NPM registry. #257

Security Updates

  • Set common HTTP security headers in the Retail React App. #263
  • Remove upgrade-insecure-requests for local development. #270

Other Changes

  • Locale-based URLs. You can include the locale in the URL path or as a query parameter using the new configuration in pwa-kit-config.json. #228 #255
  • All configuration options related to the Commerce API and the Einstein API that were previously in commerce-api.config.js and einstein-api.config.js are now in one file: api.config.js. #256
  • The new DynamicImage can transform your images by mapping an array of widths to the corresponding sizes and srcSet attributes. This component also makes it easier to use the Dynamic Imaging Service. #186
  • The query parameters mobify_server_only and mobify_pretty used for debugging are now called __server_only and __pretty_print. The old query parameters are deprecated but still work. #250
  • New id and defaultMessage parameters to enable translation for the Retail React App. #195 #207 #239 #252 #260
  • New example product scroller on the home page of the Retail React App. #218 #208 #216
  • The outputDir option for the npx pwa-kit-create-app script defaults to pwa-kit-starter-project instead of generated-project. #268
  • The Seo component now fetches the default site title from pages/constants.js. #279
  • The createApp function takes a new option called enableLegacyRemoteProxying that defaults to true. When set to false, local development proxying is disabled when running remotely. In future, local development proxying will always be disabled when running remotely. #205
  • More informative error output when the locale configured in PWA kit doesn’t match the one in Business Manager. #225
  • Improvements to README.md and CONTRIBUTING.md files for the repository. #241 #251 #271 #281
  • Error messages point to the latest documentation and help topics. #268
  • New and updated tests for search pages. #245

v1.2.0

22 Nov 21:45
dfa68de

Choose a tag to compare

🥳 This release focuses on a number of updates for localization and improvements related to SEO, performance, and shopper experience.

Changes

Full changelog: v1.1.0...v1.2.0

Retail React App: Localization

You can now build translation bundles using npm run build-translations as well as associate locale selectors with preferred currencies. Configurations are enabled so that you can keep all localization-related configurations in one place. For more information about localization, see the Localization README.

  • Use the preferred currency when switching locales. #105
  • When adding a new locale, minimize configuring the locale selector UI by having a list of commonly-used locales #175
  • Rename the extract-messages and compile-messages commands to extract-default-translations and compile-translations #160
  • For search engine crawlers, add hreflang links to the current page's HTML #137
  • Allow individual Commerce API calls to pass in a different locale/currency and override the global value. #177
  • Enabling pseudo locale now affects only the loading of the translation messages. The rest of the app still knows about English and the other locales. #177
  • Fix regression with loading the correct translation file #193
  • Fix Missing Locale Param for Commerce API Calls #174

Retail React App: Performance & Usability

A new simplified homepage makes it easier to get started with developing your storefront. We also implemented a couple of other fixes for performance and usability.

  • Simplified storefront homepage #201
  • Add cache-control header to product details page #172

Retail React App: Shopper Experience

Improvements in Einstein recommendation and wishlists enhance the shopper experience for the storefront.

  • Ensure cookieId value is sent always for Einstein recommendations #179
  • Integrate wishlist with Einstein recommended products. #131
  • Enable favorite icons on product tiles for guest users #173
  • Fix: Enable adding wishlist items to the cart. #158
  • Rename CartItemVariant to ItemVariantProvider to improve reuse. #155

Fixes and Security Updates

  • Remove x-powered-by HTTP response header #165
  • Upgrade chakra-ui/react to ^1.7.1 version. #204
  • Upgrade copy-webpack-plugin to fix tar vulnerability #181
  • Clear SLAS tokens when OID is changed, so that when you connect to the different sandbox the new tokens are used #178
  • Security package updates