-
Notifications
You must be signed in to change notification settings - Fork 1
feat: implement wallet-adapter #11
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
base: main
Are you sure you want to change the base?
Conversation
| }) | ||
| export class AccountService { | ||
| private readonly connection = new Connection(clusterApiUrl('devnet')); | ||
| private readonly _key = 'BJyq3roxaYEsPTs2'; |
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.
Key is not used.
| CommonModule, | ||
| AppHeroComponent, | ||
| RouterLink, | ||
| JsonPipe, |
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.
JsonPipe is no longer used.
| template: ` | ||
| @if(publicKey()){ | ||
| <div> | ||
| <a [routerLink]="['account/:c']">{{ publicKey() }}</a> |
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.
We can remove the route and change the logic:
@if (!publicKey()) {
// select wallet
}
| @Component({ | ||
| selector: 'dapp-account-balance', | ||
| standalone: true, | ||
| imports: [CommonModule, JsonPipe, BalanceSolComponent], |
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.
No need for JsonPipe
| @@ -1,11 +1,15 @@ | |||
| import { CommonModule } from '@angular/common'; | |||
| import { Component } from '@angular/core'; | |||
| import { Component, effect, inject } from '@angular/core'; | |||
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.
effect is not needed here
No description provided.