Blazor & WASM in combination to get statistics from Spotify API for performing the song analysis. With separate microservices for auth, Spotify, user data tracking, and application, connected through gRPC with Polly.
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

Index.razor 1.0KB

12345678910111213141516171819202122232425262728
  1. @page "/"
  2. @using Grpc.Net.Client
  3. @using Grpc.Net.Client.Web
  4. @using GrpcShared
  5. @using GrpcShared.DTO.Auth
  6. @using NemAnBlazor.Services.Interfaces
  7. @inject NavigationManager NavigationManager
  8. @inject IAuthClientService AuthService
  9. @*@inject ISearchClientService SearchService*@
  10. <PageTitle>Index</PageTitle>
  11. <h1>Pozdrav Diligent!</h1>
  12. Dobrodošli u našu NemAn aplikaciju.
  13. @code {
  14. protected override async Task OnInitializedAsync()
  15. {
  16. //var response = await SearchService.GetListSearchAsync(new GrpcShared.DTO.Search.SearchRequest() { Query="venom", Type = "track"});
  17. CodeRequest authParams = await AuthService.GetAuthParams();
  18. // await AuthService.GetAccessToken(new CodeResponse{ Code = "hello"});
  19. string url = $"https://accounts.spotify.com/en/authorize?client_id={authParams.ClientId}&redirect_uri={authParams.RedirectURI}&response_type={authParams.ResponseType}&scope={authParams.Scope}&show_dialog={authParams.ShowDialog}";
  20. NavigationManager.NavigateTo(url);
  21. }
  22. }