post static method

Future<Response> post(
  1. String path, {
  2. bool showLoading = false,
  3. DioMethod method = DioMethod.post,
  4. Map<String, dynamic>? params,
  5. CancelToken? cancelToken,
  6. Options? options,
})

http POST request return Future

Implementation

static Future<Response> post(
  String path, {
  bool showLoading = false,
  DioMethod method = DioMethod.post,
  Map<String, dynamic>? params,
  CancelToken? cancelToken,
  Options? options,
}) {
  return HttpUtils()
      .request(path, showLoading: showLoading, method: method, data: params, options: options, cancelToken: cancelToken);
}