Colton Idle
10/19/2023, 9:10 PM@Stable
annotation or used immutable collections. Never had any perf issues and I've had some complex layouts I've had to implement. Is it just me? Should I be using @stable
?Pablichjenkov
10/19/2023, 9:15 PMTravis Griggs
10/19/2023, 10:07 PMFrancesc
10/19/2023, 10:47 PMPablichjenkov
10/19/2023, 10:56 PMBen Trengrove [G]
10/19/2023, 11:11 PMeygraber
10/20/2023, 1:32 AMcurioustechizen
10/20/2023, 2:07 AMBen Trengrove [G]
10/20/2023, 2:32 AMPablichjenkov
10/20/2023, 2:40 AMBen Trengrove [G]
10/20/2023, 2:40 AMPablichjenkov
10/20/2023, 2:41 AMvide
10/20/2023, 4:44 AMPablichjenkov
10/20/2023, 4:55 AMvide
10/20/2023, 5:04 AMBen Trengrove [G]
10/20/2023, 5:31 AMPablichjenkov
10/20/2023, 5:41 AMinstance equality
. Developers should know how to play with and propbably there is some edge cases, but it looks like most people are representing state with sealed + data classes
and using copy
to update the state, which makes the whole thing a great combination.Zoltan Demant
10/20/2023, 8:39 AM@Immutable
in an earlier project with performance problems (many complex screens, too). It did resolve the performance issues, but more notably: theres a clear difference in fluidity as compared to newer projects without the optimizations (despite the newer projects using the reworked Modifiers even; they werent available back then). Having the "optimized" version enabled by default would be awesome 👍🏽vide
10/20/2023, 9:58 AMBen Trengrove [G]
10/20/2023, 10:04 AMPablichjenkov
10/20/2023, 10:15 AMeygraber
10/20/2023, 11:36 AMColton Idle
10/20/2023, 1:06 PMascii
10/20/2023, 1:08 PMstable
by the compiler, as long as it can see that code. For example, a data class with only `val`s inside it doesn't need to be marked with any stability annotations.Ben Trengrove [G]
10/20/2023, 7:56 PMascii
11/08/2023, 5:14 AMZoltan Demant
11/08/2023, 5:42 AMPablichjenkov
11/08/2023, 5:43 AMcom.mypackage.**
Zoltan Demant
11/08/2023, 5:47 AMColton Idle
11/08/2023, 8:28 AMvide
11/08/2023, 8:36 AMBen Trengrove [G]
11/08/2023, 9:03 AMvide
11/08/2023, 3:02 PMColton Idle
11/15/2023, 9:42 PMFrancesc
11/15/2023, 9:54 PMColton Idle
11/15/2023, 9:57 PMFrancesc
11/15/2023, 9:59 PMColton Idle
11/15/2023, 10:07 PMascii
11/15/2023, 10:14 PMplugin:androidx.compose.compiler.plugins.kotlin:experimentalStrongSkipping=true
Add it to your freeCompilerArgs or in the compose
block if CMP.Ben Trengrove [G]
11/15/2023, 10:22 PMColton Idle
11/15/2023, 10:27 PMBen Trengrove [G]
11/15/2023, 10:31 PMColton Idle
11/15/2023, 10:32 PMascii
11/15/2023, 10:33 PMColton Idle
11/15/2023, 10:40 PMFrancesc
11/15/2023, 10:41 PMfreeCompilerArgs += listOf(
"-P",
"plugin:androidx.compose.compiler.plugins.kotlin:experimentalStrongSkipping=true"
)
Colton Idle
11/16/2023, 12:20 PM