simulateApiCall method

Future<void> simulateApiCall({
  1. Duration? duration,
})

Call this function to simulate an interval seconds to wait before get the fake data from the fake api call

Implementation

Future<void> simulateApiCall({Duration? duration}) async {
  await Future.delayed(duration ?? Duration(milliseconds: 80));
}