airbnb / Showkase

🔦 Showkase is an annotation-processor based Android library that helps you organize, discover, search and visualize Jetpack Compose UI elements
https://medium.com/airbnb-engineering/introducing-showkase-a-library-to-organize-discover-and-visualize-your-jetpack-compose-elements-d5c34ef01095
Apache License 2.0
2.13k stars 107 forks source link

Issue 215 Add order parameter to Showkase annotation #217

Closed themanol closed 1 year ago

themanol commented 2 years ago

Adding a parameter to the Showkase Annotations that allow customise the order of the element in the ShowkaseBrowser. Screenshot 2022-01-25 at 16 38 17

themanol commented 2 years ago

Hi, do you think this could be interesting for merging in the next release? thanks!

marcorighini commented 2 years ago

This looks like an interesting improvement to give the possibility to order the components. Is there a plan to merge it @vinaygaba ?

vinaygaba commented 2 years ago

@marcorighini I'm not a fan of adding so many one off properties to @ShowkaseComposable. It's not elegant - moreover, Showkase exposes all your previews that it collects through the Showkase.getMetadata() function (more info here - https://github.com/airbnb/Showkase#5-showkase-object). Using this metadata object, it would be trivial to create your own browser that behaves exactly how you want it to behave.

vinaygaba commented 1 year ago

Closing this PR as I think using the Showkase metadata API for creating a custom browser for your use cases might be a better approach.