dash_kit_network 3.6.0 copy "dash_kit_network: ^3.6.0" to clipboard
dash_kit_network: ^3.6.0 copied to clipboard

The DashKit plugin that provides basic network functionality including token refresh.

example/lib/main.dart

import 'package:dash_kit_network/dash_kit_network.dart';
import 'package:example/api/application_api.dart';
import 'package:example/app.dart';
import 'package:flutter/material.dart';

void main() {
  final dio = Dio();

  const apiEnvironment = ApiEnvironment(
    baseUrl: 'https://reqres.in/api/',
    validateRequestsByDefault: false,
  );

  final apiClient = ApplicationApi(
    dio: dio,
    environment: apiEnvironment,
  );

  dio.interceptors.add(LogInterceptor(
    requestBody: true,
    responseBody: true,
  ));

  runApp(MyApp(
    apiClient: apiClient,
  ));
}
11
likes
0
pub points
56%
popularity

Publisher

verified publisherdash-kit.blogspot.com

The DashKit plugin that provides basic network functionality including token refresh.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

dio, flutter, flutter_secure_storage, rxdart, shared_preferences

More

Packages that depend on dash_kit_network