Replies: 1 comment
-
|
I work around the scenario. Here below the code. PageTrackerServices Class: When call MainLayout.Razer: In the OnInitialized() event of MainLayout.razor, OnPageChanged event is handled using InvokeAsync to switch to the UI thread. Below is the code to display current page name and interfaces. Hope this implementation align with your scenario. |
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
Uh oh!
There was an error while loading. Please reload this page.
-
Now in a Blazor layout to detect the current page I have to check the current uri with NavigationManager.
I would like to get access from the layout to the class name of the current Blazor component with page directive inside the body of the layout to see if it implements an interface. This is more general than checking an uri with string comparison.
Beta Was this translation helpful? Give feedback.
All reactions