Search packages, repositories and app categories

Package detailsv2.2.2

dio_web_adapter

An adapter that supports Dio on Web.

Web
30-day downloads
5.3M
Likes
5
Pub points
150

Install package

flutter pub add dio_web_adapter

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

Dio Web Adapter is a plugin that enables the Dio HTTP client to function seamlessly on web platforms. It provides web-specific implementations for network requests, ensuring compatibility with browser-based environments. By integrating this adapter, developers can use Dio's powerful features—such as request/response interceptors, headers, and error handling—across both mobile and web applications with consistent behavior. The adapter leverages the browser's built-in fetch API under the hood, offering reliable and performant HTTP communication in web contexts.

Use cases

  • Making HTTP requests in Flutter web apps
  • Integrating Dio with web APIs
  • Sharing HTTP logic between mobile and web
  • Handling JSON responses on the web
  • Using interceptors in web environments

Key features

  • Web-compatible HTTP requests
  • Uses browser fetch API
  • Supports Dio's full feature set on web
  • Easy integration with existing Dio code
  • Consistent behavior across platforms

Suitable for

  • Flutter developers targeting web
  • Projects using Dio for HTTP operations
  • Cross-platform apps requiring web support
  • Teams wanting unified HTTP handling
  • Apps needing interceptors and middleware on web

Considerations

  • Requires Dio to be installed
  • Limited to web platform
  • May need additional configuration for CORS
  • Depends on browser fetch capabilities
  • Not needed for non-web targets

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

dio

Language: English | 简体中文

This is the base repo of the dio project. Please move to specific paths for project instructions.

Don't forget to add #dio topic to your published dio-related packages! See more: https://dart.dev/tools/pub/pubspec#topics

Versioning

Before you upgrade: Breaking changes might happen in major and minor versions of packages.
See the Migration Guide for the complete breaking changes list.

To know about our compatibility policy, see the Compatibility Policy doc.

All Packages

dio
Plugins
  • cookie_manager: link Pub
  • compatibility_layer: link Pub
  • http2_adapter: link Pub
  • native_dio_adapter: link Pub
  • web_adapter: link Pub
Examples
  • example: link
  • example_flutter_app: link

Copyright & License

The project and its underlying projects are originally authored by @wendux with the organization @flutterchina, started being maintained by Chinese Flutter User Group (@cfug) since 2023.

The project consents the MIT license.

Categories

Dependencies

Dependency list 4 items

Source repository

Projects using this package

No data available yet.