question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Multi-modules project : how to avoid public visibility for @Preview?

See original GitHub issue

The documentation states that

The root module is the main module of your app that has a dependency on all other modules in the app. This is relevant because we generate the Showkase related classes in the package of the root module and we need to be able to access the UI elements across all the sub modules. This is only possible from the root module as it typically has a dependency on all the sub-modules.

  • Does it mean that we can only have one @ShowkaseRootModule per project?

  • Setting all the composables to render with a public visibility adds unnecessary items to the auto-completion list. Do you have an idea to help mitigate this?

Many thanks!

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:2
  • Comments:5

github_iconTop GitHub Comments

1reaction
borsinicommented, Oct 11, 2022

Thanks @iamutkarshtiwari , that would be an alternative. We ended up excluding our Previews from the IDE autocompletion-list.

Regarding my first question, does anyone have a clue? maybe @vinaygaba ? Having multiple ShowkaseRoot would help isolate previews and keep them internal

Does it mean that we can only have one @ShowkaseRootModule per project?

0reactions
vinaygabacommented, Dec 19, 2022

Does it mean that we can only have one @ShowkaseRootModule per project?

ShowkaseRootModule are essentially meant to represent a collection previews based on the dependencies of the module where its declared. So in theory, it’s possible to have multiple ShowkaseRootModule in a project.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Navigation best practices for multi-module projects
With this code in place, NavigationUI navigates to the appropriate library graph when the user clicks on a bottom navigation item. Keep in...
Read more >
Jetpack Compose does not compile in a multi-module project
I never managed to compile a multi-module project with any of the compose developer preview versions, I asked a lot in the official...
Read more >
Managing visibility of your projects - GitHub Docs
Visibility of user projects can be managed by the owner of the project and collaborators with admin permissions. About project visibility. Projects can...
Read more >
Modularization - Lessons learned - Jeroen Mols
That way the layout previews will be shown in the correct theme by default! Layout preview shows correct theme when application theme attribute ......
Read more >
Easy modularity: Keeping your Gradle build scripts clean and ...
... scripts clean and eliminating duplication in your multi-module projects ... Apply only what you need and no more: plugins are not free....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found