Skip to content
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

feat: add emitter event on location change #304

Merged
merged 14 commits into from
Oct 2, 2024

Conversation

dennyscode
Copy link
Contributor

packages/widget/src/types/events.ts Outdated Show resolved Hide resolved
packages/widget/src/types/events.ts Show resolved Hide resolved
@@ -30,6 +31,7 @@ export type WidgetEvents = {
reviewTransactionPageEntered?: Route;
walletConnected: WalletConnected;
widgetExpanded: boolean;
page: string;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's create a union type from navigationRoutes constant instead of string that lists all relevant pages we would like to track, except maybe home? Let me please know what do you think :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea! I have re-used the existing NavigationRouteType.

Just not sure with this: To silence ts, I have used it that way here:
image

packages/widget/src/AppRoutes.tsx Outdated Show resolved Hide resolved
@chybisov chybisov merged commit d6146f8 into main Oct 2, 2024
1 check passed
@chybisov chybisov deleted the LF-10006-jumper-implement-settings-tracking branch October 2, 2024 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants