This repository has been archived by the owner on May 6, 2024. It is now read-only.
PlayerService as Singleton for Blazor Server? #12
Unanswered
leandrocervant
asked this question in
Q&A
Replies: 1 comment
-
Hi @leandrocervant Looking at the class and what it does we dont need to create a new instance of that for each request! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Since the DI provides singleton services for webapplication instance and the PlayerService has episode interactions by user, is correct to register that as singleton?
wouldn't it be better to register as scoped?
dotnet-podcasts/src/Web/Server/Program.cs
Line 22 in 42547f8
Beta Was this translation helpful? Give feedback.
All reactions