rundfunk47 / stinsen

Coordinators in SwiftUI. Simple, powerful and elegant.
MIT License
907 stars 95 forks source link

Can't get NavigationRouter via protocol #118

Open PortgasDTee opened 1 year ago

PortgasDTee commented 1 year ago

@RouterObject var authRouter: NavigationRouter<AuthCoordinatorType>? AuthCoordinator have been init and router stored but when I use authRouter, it is nil

protocol AuthCoordinatorType: AnyObject {}

final class AuthCoordinator: AuthCoordinatorType, NavigationCoordinatable { lazy var routerStorable: AuthCoordinatorType = self ... }

I checked on func func retrieve<T: Routable>() -> T? in class RouterStore Stored router have type NavigationRouter<AuthCoordinator> can't cast to NavigationRouter<AuthCoordinatorType>