-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consume new version of the commerce-sdk-isomorphic to enable Phased Launches support HTTP Basic Auth #1153
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tarcang
reviewed
Apr 27, 2023
alexvuong
commented
Apr 27, 2023
@@ -16,7 +16,13 @@ describe('Shopper Baskets hooks', () => { | |||
const unimplemented = getUnimplementedEndpoints(ShopperBaskets, queries, mutations) | |||
// If this test fails: create a new query hook, add the endpoint to the mutations enum, | |||
// or add it to the `expected` array with a comment explaining "TODO" or "never" (and why). | |||
expect(unimplemented).toEqual([]) | |||
expect(unimplemented).toEqual([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Version 1.10.1 adds some more basket mutations.
bfeister
approved these changes
Apr 27, 2023
kevinxh
approved these changes
Apr 27, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
I guess this is how you include cookies right?
<CommerceApiProvider
fetchOptions={{credentials: 'include'}}
/ >
bfeister
added a commit
that referenced
this pull request
May 9, 2023
* v3: fix: remove device-context and detect-device-type (#1168) Dependency updates (#1170) [Snyk] Security upgrade cosmiconfig from 7.1.0 to 8.0.0 (#1145) [V3] Remove `cross-fetch` from `template-retail-react-app` (#1160) [v3] Add suffix to ssr build files (#1158) Consume new version of the commerce-sdk-isomorphic to enable Phased Launches support HTTP Basic Auth (#1153) # Conflicts: # packages/commerce-sdk-react/package-lock.json # packages/internal-lib-build/package-lock.json # packages/pwa-kit-runtime/package-lock.json # packages/template-retail-react-app/package-lock.json
bfeister
added a commit
that referenced
this pull request
May 9, 2023
…xtensibility-algo-refactor + regen lockfiles * feature/template-extensibility: regen package lockfiles fix: remove device-context and detect-device-type (#1168) Dependency updates (#1170) [Snyk] Security upgrade cosmiconfig from 7.1.0 to 8.0.0 (#1145) [V3] Remove `cross-fetch` from `template-retail-react-app` (#1160) [v3] Add suffix to ssr build files (#1158) Consume new version of the commerce-sdk-isomorphic to enable Phased Launches support HTTP Basic Auth (#1153) # Conflicts: # package-lock.json # packages/commerce-sdk-react/package-lock.json # packages/internal-lib-build/package-lock.json # packages/my-extended-retail-app/package-lock.json # packages/pwa-kit-create-app/package-lock.json # packages/pwa-kit-dev/package-lock.json # packages/pwa-kit-react-sdk/package-lock.json # packages/pwa-kit-runtime/package-lock.json # packages/template-retail-react-app/app/hooks/use-einstein.test.js # packages/template-retail-react-app/package-lock.json # packages/template-typescript-minimal/package-lock.json # packages/test-commerce-sdk-react/package-lock.json
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
If a customer enables storefront protection on ECOM (so common could be considered the default in non-prod environment) it requires the HTTP Basic Auth header passed via the HTTP Request header
authorization
.This messes with the
authorization
header used to send requests to SCAPI.To resolve, this, we should look to transition
commerce-sdk-isomorphic
to usefetch
and passfetch(url, {credentials: 'omit'})
to disable browser's default behaviour of forwarding previously used basic auth headers.Types of Changes
Changes
How to Test-Drive This PR
-boost up retail app
Checklists
General
Accessibility Compliance
You must check off all items in one of the follow two lists:
or...
Localization