-
Notifications
You must be signed in to change notification settings - Fork 81
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
Fix back stack for embedded apps #814
Conversation
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.
Just some nits, but holding off on approving until we figure out whether tests make sense for this :)
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.
Could / should we have some tests for these changes? We could create a folder around this or add them to the existing AppProvider tests (which is the only place that will use this).
); | ||
}) as LinkLikeComponent; | ||
|
||
function parseUrl(url: string | undefined | null) { |
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.
Total nit, but does undefined
vs null
matter here? It seems like we could just use undefined
all around?
e58a70d
to
9f2bda1
Compare
Co-authored-by: Paulo Margarido <64600052+paulomarg@users.noreply.github.com>
9f2bda1
to
a2073de
Compare
@@ -3,7 +3,8 @@ | |||
"compilerOptions": { | |||
"baseUrl": ".", | |||
"outDir": "./dist/ts", | |||
"rootDir": "src" | |||
"rootDir": "src", | |||
"types": ["@cloudflare/workers-types", "node", "jest", "jsdom"] |
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.
I wonder if it's worth creating a separate test config that extends this one and adds the jsdom
types so we don't affect production builds with them. WDYT?
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.
Production build uses tsconfig.build.json
, doesn't it?
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.
But it extends that one. We could also override the build config to set all types but jsdom, that would work :)
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.
🎩 via https://github.com/Shopify/app-bridge-next/pull/345
Agree on adding unit tests :)
Close as we are working on a solution that doesn't involve update in the template |
WHY are these changes introduced?
Resolves part of Shopify/shopify-app-bridge#313
WHAT is this pull request doing?
This PR fixes Link Component to work with back stack in embedded apps.
Type of change
Checklist
yarn changeset
to create a draft changelog entry (do NOT update theCHANGELOG.md
files manually)