0

I have a many pages and I want to check every time this page call, if JWT TOKEN is expired. Do I have to call this function in every page or can I for example insert it only in the main.dart?

joisberg
  • 175
  • 2
  • 13

1 Answers1

0

You can listen/observ to the naviation : Observer for Navigator route changes in Flutter

And excecute you JWT token check method there.

BabC
  • 1,044
  • 5
  • 18