-
Notifications
You must be signed in to change notification settings - Fork 346
chore(clerk-js): Use local environment on outage #5420
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
🦋 Changeset detectedLatest commit: 9bad073 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
.catch(e => { | ||
const environmentSnapshot = SafeLocalStorage.getItem<EnvironmentJSONSnapshot | null>( | ||
CLERK_ENVIRONMENT_STORAGE_ENTRY, | ||
null, | ||
); | ||
|
||
if (!environmentSnapshot) { | ||
throw e; | ||
} | ||
|
||
this.updateEnvironment(new Environment(environmentSnapshot)); |
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 am wondering if this logic shouldn't be contained within the EnvironmentResource class. Seems like it could simplify the implementation overall
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 am a bit confused here, are you advocating for this to be included in the Environment class because currently it is not.
If that is the case, I'd suggest doing this in another follow up PR, which will improve the overall architecture which would handle this for non-standard browsers (e.g. Expo).
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.
@panteliselef Yes, I think having this logic be encapsulated in the EnvrionmentResource class would be preferrable. No issue with doing it as a follow up
…-locally # Conflicts: # packages/clerk-js/bundlewatch.config.json
!snapshot |
Hey @panteliselef - the snapshot version command generated the following package versions:
Tip: Use the snippet copy button below to quickly install the required packages. npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact
npm i @clerk/[email protected] --save-exact |
Description
Checklist
pnpm test
runs as expected.pnpm build
runs as expected.Type of change