What do the @Stable and @Immutable annotations mean in Jetpack Compose?
The definition @Immutable is an annotation to tell Compose compiler that this object is immutable for optimization, so without using it, there will be unnecessary re-composition that might get triggered. @Stable is another annotation to tell the Compose compiler that this object might change, but when it changes, Compose runtime will be notified. It might … Read more