Skip to content

Fix MRT Data Store env var names in generated config and README - #3823

Merged
adamraya merged 2 commits into
bump-3.18.0-preview.2from
a2-mrt-data-store-doc-fix
May 7, 2026
Merged

Fix MRT Data Store env var names in generated config and README#3823
adamraya merged 2 commits into
bump-3.18.0-preview.2from
a2-mrt-data-store-doc-fix

Conversation

@adamraya

@adamraya adamraya commented May 7, 2026

Copy link
Copy Markdown
Contributor

Summary

  • The generator templates and the retail-react-app README referenced PWAKIT_MRT_DATA_STORE_DEFAULTS and PWAKIT_MRT_DATA_STORE_WARN_ON_MISSING, but @salesforce/mrt-utilities actually reads the unprefixed MRT_DATA_STORE_DEFAULTS and MRT_DATA_STORE_WARN_ON_MISSING. Renamed in the comments and the README so copy-pasting from generated projects works.
  • Removed the reference to PWAKIT_MRT_DATA_STORE_ALLOW_LOCAL, which is not consumed anywhere in this repo or in @salesforce/mrt-utilities.
  • Aligns the generator/README with the rename already noted in the @salesforce/pwa-kit-runtime 3.18.0 changelog.

Found while validating PWA Kit 3.18.0-preview.1: setting the PWAKIT_*-prefixed defaults env vars produced no __MRT_DATA_STORE__ data because the names didn't match what mrt-utilities/dist/*/data-store/development.js reads.

Test plan

Run from a freshly generated 3.18 project:

PWAKIT_MRT_DATA_STORE_ENABLED=true \
MRT_DATA_STORE_DEFAULTS='{"custom-global-preferences":{"testFeature":true},"RefArch-custom-site-preferences":{"storeName":"Test Store RefArch"}}' \
npm start
  • view-source:http://localhost:3000/RefArch/ includes __MRT_DATA_STORE__ under #mobify-data with the seeded values.
  • Default-off path: without PWAKIT_MRT_DATA_STORE_ENABLED, the key is omitted (regression check).
  • No runtime files touched — comments and README only.

The generator templates and the retail-react-app README referenced
PWAKIT_MRT_DATA_STORE_DEFAULTS and PWAKIT_MRT_DATA_STORE_WARN_ON_MISSING,
but @salesforce/mrt-utilities reads the unprefixed MRT_DATA_STORE_DEFAULTS
and MRT_DATA_STORE_WARN_ON_MISSING. Also drop the reference to
PWAKIT_MRT_DATA_STORE_ALLOW_LOCAL, which is not consumed anywhere.

Aligns the docs with the rename called out in the pwa-kit-runtime
3.18.0 changelog so devs copy-pasting from the comments don't end up
with env vars that silently do nothing.
@adamraya
adamraya requested a review from a team as a code owner May 7, 2026 20:40
@git2gus

git2gus Bot commented May 7, 2026

Copy link
Copy Markdown

Git2Gus App is installed but the .git2gus/config.json doesn't have right values. You should add the required configuration.

@cc-prodsec

cc-prodsec commented May 7, 2026

Copy link
Copy Markdown
Collaborator

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@adamraya adamraya added the skip changelog Skip the "Changelog Check" GitHub Actions step even if the Changelog.md files are not updated label May 7, 2026
@adamraya
adamraya merged commit ea11dea into bump-3.18.0-preview.2 May 7, 2026
41 checks passed
@adamraya
adamraya deleted the a2-mrt-data-store-doc-fix branch May 7, 2026 21:11
adamraya added a commit that referenced this pull request May 7, 2026
* Add Node 24 support to extensible app template

Update engines in package.json.hbs to include Node 24.
This ensures new extensible apps created with pwa-kit-create-app
will support Node 24.x (^24.0.0).

The npm range already supports npm 11 which ships with Node 24.

* Retrigger CI

* Re-add cookieDomain to Auth constructor (#3822)

* Fix MRT Data Store env var names in generated config and README (#3823)

* Fix MRT Data Store env var names in generated config and README

The generator templates and the retail-react-app README referenced
PWAKIT_MRT_DATA_STORE_DEFAULTS and PWAKIT_MRT_DATA_STORE_WARN_ON_MISSING,
but @salesforce/mrt-utilities reads the unprefixed MRT_DATA_STORE_DEFAULTS
and MRT_DATA_STORE_WARN_ON_MISSING. Also drop the reference to
PWAKIT_MRT_DATA_STORE_ALLOW_LOCAL, which is not consumed anywhere.

Aligns the docs with the rename called out in the pwa-kit-runtime
3.18.0 changelog so devs copy-pasting from the comments don't end up
with env vars that silently do nothing.

* Retrigger CI

* Bump versions to 3.18.0-preview.2

- commerce-sdk-react: 5.2.0-preview.1 → 5.2.0-preview.2
- pwa-kit packages: 3.18.0-preview.1 → 3.18.0-preview.2
- Update CHANGELOGs with preview.2 release entries

---------

Co-authored-by: vcua-mobify <47404250+vcua-mobify@users.noreply.github.com>
rfding pushed a commit to rfding/pwa-kit that referenced this pull request May 15, 2026
- @salesforce/pwa-kit-runtime, pwa-kit-react-sdk, pwa-kit-dev,
  pwa-kit-create-app: 3.18.0-preview.2 → 3.18.0
- @salesforce/commerce-sdk-react: 5.2.0-preview.2 → 5.2.0
- @salesforce/retail-react-app: 10.0.0-preview.2 → 10.0.0
- lerna.json + root package.json bumped to 3.18.0
- All package-lock.json files refreshed by `npm install`

Collapse preview.0/preview.1/preview.2 CHANGELOG headings into the final
3.18.0 / 5.2.0 / 10.0.0 entries, per the release process. Add the
preview.2 entries that were not already in the changelogs:
- SalesforceCommerceCloud#3821 Node 24 in extensible app template
- SalesforceCommerceCloud#3822 Re-add cookieDomain to Auth constructor
- SalesforceCommerceCloud#3823 Fix MRT Data Store env var names in generated config and README
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip changelog Skip the "Changelog Check" GitHub Actions step even if the Changelog.md files are not updated

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants