CaiJingLong / flutter_load_widget

Apache License 2.0
35 stars 13 forks source link

LoadingProvider throws away entire widget tree #16

Open DreadBoy opened 3 years ago

DreadBoy commented 3 years ago

Including provider this way:

MaterialApp(
  builder: (context, widget) {
    return LoadingProvider(
      child: widget,
    );
  },
);

throws away entire widget tree inside LoadingProvider if anything above changes, for example EasyLocalization locale or some other provider. This is performance problem. Rebuilding widget tree is fine, throwing it away by changing widget key and rebuilding it is wasteful. Is this intentional behaviour or bug?