docs(AudioPlayerProvider): explain IsFixed=true intent and runtime-swap caveat

This commit is contained in:
Daniel Harvey
2026-05-21 07:52:13 -04:00
parent b4fff43cb3
commit 5d823868c8
@@ -1,3 +1,7 @@
<CascadingValue Value="@(_audioPlayerService)" IsFixed="true">
@* IsFixed="true": the StreamingAudioPlayerService instance is created once in OnInitialized
and is never replaced — the reference is stable for the lifetime of the component.
If instance swapping at runtime is ever needed, change IsFixed to false (adds subscription
overhead on every parent re-render, but allows children to see the new reference). *@
<CascadingValue Value="@(_audioPlayerService)" IsFixed="true">
@ChildContent
</CascadingValue>