Wednesday, July 20, 2022

GetX Route with Named

GetX Route with Named


void main() {

  runApp(GetMaterialApp(

    initialRoute: '/home',

    getPages: [

      GetPage(name: '/home', page: () => First(), binding: SampleBind()),
   
],
  ));
}


class SampleBind extends Bindings {
  @override

  void dependencies() {

    Get.lazyPut<Controller>(() => Controller());
    Get.lazyPut<Controller2>(() => Controller2());
    Get.lazyPut<Controller3>(() => Controller3());
 
    }
}

No comments:

Post a Comment

Featured post

Compress Image With Show File Size & Resolution in Flutter

 Compress Image With Show File Size & Resolution  1.Multiple File Image Compress with file Size import 'dart:io' ; import 'p...

LightBlog