I'm trying to implement the following if a user is logged in can't navigate to specific pages like login, register ...etc and if login the same can't navigate to profile ...etc
I'm using a flutter bloc Package and I have done the Authentication bloc and works great now my issue that I have ( I guess ) to access the Authentication bloc to check if the user authenticated or not and return a boolean depends on that!
I'm trying to implement the following if a user is logged in can't navigate to specific pages like login, register ...etc and if login the same can't navigate to profile ...etc
I'm using a flutter bloc Package and I have done the Authentication bloc and works great now my issue that I have ( I guess ) to access the Authentication bloc to check if the user authenticated or not and return a boolean depends on that!
So be something like that
But the problem I can't do that as far I know in SailorRouteGaurds!! or I don't know how to implement this