flutterchina / flutter_in_action_2nd

《Flutter实战 第二版》 书稿
https://book.flutterchina.club/
2.24k stars 349 forks source link

animatedList code bug #33

Closed FycGitHub closed 2 years ago

FycGitHub commented 3 years ago

var item = buildItem(context, index); data.removeAt(index); print('删除 ${data[index]}');

Should be changed to var item = buildItem(context, index); print('删除 ${data[index]}'); data.removeAt(index);

FycGitHub commented 3 years ago

https://book.flutterchina.club/chapter6/animatedlist.html 第六章 可滚动组件 6.5中的案例代码

hevi1991 commented 3 years ago

此示例,若点击删除过快,会发生数组越界的异常

wendux commented 2 years ago

get