'How to send consumable events through jetpack compose navigation

is there any possibility to sent over a consumable one-time event when navigating to another (unrelated and therefore not sharing the same viewmodel) screen in jetpack compose navigation? When handing over an argument via navigation, this value is not being consumed and therefore still present when navigating back and forth between different screens always re-triggering this event.

Do you know an elegant way to archive this? I want to avoid having something like a SharedFlow on Activity level and every Screen to collect it or to use SharedPrefs / DataStore to temporarely store those events. Thank you very much.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source