onItemClick method

void onItemClick(
  1. int index,
  2. People obj
)

Implementation

void onItemClick(int index, People obj) {
  ScaffoldMessenger.of(_scaffoldCtx).showSnackBar(SnackBar(
    content: Text(obj.name! + " clicked"),
    duration: Duration(seconds: 1),
  ));
}