René Jochum

Blog of René Jochum - A FOSS enthusiast programming since 2002.

Flutter simple router

For the Let’s Check App I’m writing I needed a simple router. I haven’t found anything that suited my needs so I decided to role my own. My implementation supports: Regex named Args All routes named, this allows usage like: ( GlobalRouter().buildUri(routeSettingsConnection, buildArgs: {"alias": "JOCHUM"});) Static/Dynamic routes (Static string or Regex) Dynamicaly register/deregister routes as needed The Router implementation I have this saved as GlobalRouter.dart import 'package:flutter/foundation.dart'; import 'package:flutter/material.