loading method

dynamic loading(
  1. Future f
)

Implementation

loading(Future f) async {
  showLoading();
  try {
    return await f;
  } finally {
    hideLoading();
  }
}