They behave as something between an object constru...
# compose
a
They behave as something between an object constructor and update function, and they're basically always nouns
👍 2
n
In the Kotlin Coding Conventions there is a exception for factory functions. Do the Compose functions act like factory functions?
a
Yes, but in a rather special way since you don't get a reference to a backing object, and the system can choose to reuse/update an existing composable during a recomposition
so yes, you can think of them sort of like a factory function that can memoize/reuse objects
n
In other words the Compose functions are similar enough to factory functions that the Camel Case convention makes sense.
a
yep
n
That should be mentioned in the JetPack Compose FAQ.