tezvyn:

Navigate between feature modules without direct dependencies?

Source: developer.android.comadvanced

Tests dependency inversion in modular apps. Answer by defining navigation interfaces in a shared module, implementing them in the :app module, and using DI to connect them. A red flag is suggesting direct module dependencies or using reflection for navigation.

This tests your grasp of dependency inversion for maintaining module independence. A strong answer outlines a pattern where feature modules depend on abstract navigation interfaces (e.g., in a `:navigation-api` module), which the `:app` module then implements using the actual `NavController`. This is all wired together with dependency injection. The biggest red flag is suggesting a direct dependency from one feature module to another, which defeats the purpose of modularization.

Read the original → developer.android.com

Get five bites like this every day.

Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.

Navigate between feature modules without direct dependencies? · Tezvyn