autoCompositionKeyHash
Automatically generated value for mutationId
and subscriptionId
.
This property is useful for generating a unique namespace when a key, such as MutationKey
or SubscriptionKey
, is used within a single Composable function.
NOTE: This property must only be used within a Composable function restricted to a single key (either Mutation or Subscription). It is intended to be used in a custom Composable function dedicated to handling a single key. For other use cases, it is recommended to use the auto function.
Example:
@Composable
fun rememberCreatePost(): MutationObject<Post> {
return rememberMutation(CreatePostKey(Namespace.autoCompositionKeyHash))
}
Content copied to clipboard