Thread
#compose
    theapache64

    theapache64

    1 year ago
    Question: [Navigation Compose]: How can i get number of items in the backstack using
    NavHostController
    ?
    navController.backQueue.size
    ??
    i

    Ian Lake

    1 year ago
    That is purposefully not public API
    It sounds like a case of https://xyproblem.info/
    What are you trying to do that led you to that question?
    theapache64

    theapache64

    1 year ago
    Okay 😄 I’ll come back with the problem
    but
    backQueue
    is public 🤔
    i

    Ian Lake

    1 year ago
    It is exposed only as part of the
    navigation-testing
    library in
    TestNavHostController
    theapache64

    theapache64

    1 year ago
    but, then why am not getting any warnings when I try to access in application module? 🤔
    Adam Powell

    Adam Powell

    1 year ago
    consider it the androidx version of @RequiresOptIn annotation class InternalNavigationApi; it can change without warning in any update of the library and is not intended to be used outside of the library group