xdd666t / getx_template

Used to generate the template code of GetX framework | Flutter GetX模板代码生成(一个有用的IDEA插件)
Apache License 2.0
298 stars 67 forks source link

希望可以添加綁定(binding) #12

Closed WingCH closed 3 years ago

WingCH commented 3 years ago

希望有個選項,可以增加binding 文件

xdd666t commented 3 years ago

类似这样的?

class SubjectBinding implements Bindings {
  @override
  void dependencies() {
    Get.lazyPut<SubjectController>(() => SubjectController());
  }
}
xdd666t commented 3 years ago

你可以贴下你的代码,例如

WingCH commented 3 years ago

类型这样的?

class SubjectBinding implements Bindings {
  @override
  void dependencies() {
    Get.lazyPut<SubjectController>(() => SubjectController());
  }
}

對! 就是這樣

YeFei572 commented 3 years ago

我也觉得bingding 有必要出一个,根据官方给的栗子,还是得自己加。

xdd666t commented 3 years ago

我也觉得bingding 有必要出一个,根据官方给的栗子,还是得自己加。

在爬了,在爬了。。。

xdd666t commented 3 years ago

添加binding的功能,新版本已经添加了,更新下插件吧

WingCH commented 3 years ago

感謝大大!

YeFei572 commented 3 years ago

添加binding的功能,新版本已经添加了,更新下插件吧

well done, my old baby! :thumbsup:

Pluto1219 commented 3 years ago

添加binding的功能,新版本已经添加了,更新下插件吧

"UserShareLogic" not found. You need to call "Get.put(UserShareLogic())" or "Get.lazyPut(()=>UserShareLogic())"

页面直接红了呢?大佬

xdd666t commented 3 years ago

添加binding的功能,新版本已经添加了,更新下插件吧

"UserShareLogic" not found. You need to call "Get.put(UserShareLogic())" or "Get.lazyPut(()=>UserShareLogic())"

页面直接红了呢?大佬

兄弟,用binding,需要在路由页面里绑定下

https://github.com/CNAD666/flutter_use/blob/master/lib/app/config/route_config.dart

image

Pluto1219 commented 3 years ago

添加binding的功能,新版本已经添加了,更新下插件吧

"UserShareLogic" not found. You need to call "Get.put(UserShareLogic())" or "Get.lazyPut(()=>UserShareLogic())" 页面直接红了呢?大佬

兄弟,用binding,需要在路由页面里绑定下

https://github.com/CNAD666/flutter_use/blob/master/lib/app/config/route_config.dart

image

这这这 我不配做你兄弟 谢谢大佬