Skip to content

Commit

Permalink
To diox (cfug#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexV525 authored Dec 18, 2022
1 parent 17dde49 commit 09e6f9b
Show file tree
Hide file tree
Showing 65 changed files with 178 additions and 244 deletions.
12 changes: 0 additions & 12 deletions .github/FUNDING.yml

This file was deleted.

19 changes: 9 additions & 10 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
<!-- Write down your pull request descriptions. -->

### New Pull Request Checklist

- [ ] I have read the [Documentation](https://pub.dartlang.org/packages/dio)
- [ ] I have searched for a similar pull request in the [project](https://github.com/flutterchina/dio/pulls) and found none
- [ ] I have updated this branch with the latest `develop` to avoid conflicts (via merge from master or rebase)
- [ ] I have added the required tests to prove the fix/feature I am adding
- [ ] I have read the [Documentation](https://pub.dev/documentation/diox/latest/)
- [ ] I have searched for a similar pull request in the [project](https://github.com/cfug/diox/pulls) and found none
- [ ] I have updated this branch with the latest `main` branch to avoid conflicts (via merge from master or rebase)
- [ ] I have added the required tests to prove the fix/feature I'm adding
- [ ] I have updated the documentation (if necessary)
- [ ] I have run the tests and they pass

This merge request fixes / refers to the following issues: ...

### Pull Request Description
- [ ] I have run the tests without failures

...
### Additional context and info (if any)

<!-- Provide more context and info about the PR. -->
29 changes: 0 additions & 29 deletions .github/stale.yml

This file was deleted.

37 changes: 0 additions & 37 deletions .github/workflows/test-report.yml

This file was deleted.

12 changes: 6 additions & 6 deletions README-ZH.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
# dio
# diox

Language: [English](README.md) | 简体中文

此处是 dio 项目的基础仓库。请前往项目各自的路径查看指引。
此处是 **diox** 项目的基础仓库。请前往项目各自的路径查看指引。

- dio: [链接](dio)
[![Pub](https://img.shields.io/pub/v/dio.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/dio)
- diox: [链接](dio)
[![Pub](https://img.shields.io/pub/v/diox.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/diox)

### 插件

- cookie_manager: [链接](plugins/cookie_manager)
[![Pub](https://img.shields.io/pub/v/dio_cookie_manager.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/dio_cookie_manager)
[![Pub](https://img.shields.io/pub/v/diox_cookie_manager.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/diox_cookie_manager)
- http2_adapter: [链接](plugins/http2_adapter)
[![Pub](https://img.shields.io/pub/v/dio_http2_adapter.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/dio_http2_adapter)
[![Pub](https://img.shields.io/pub/v/diox_http2_adapter.svg?label=dev&include_prereleases)](https://pub.flutter-io.cn/packages/diox_http2_adapter)

### 示例

Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
# dio
# diox

Language: English | [简体中文](README-ZH.md)

This is the base repo of the dio project.
This is the base repo of the **diox** project.
Please move specific paths for projects instructions.

- dio: [link](dio)
[![Pub](https://img.shields.io/pub/v/dio.svg?label=dev&include_prereleases)](https://pub.dev/packages/dio)
- diox: [link](dio)
[![Pub](https://img.shields.io/pub/v/diox.svg?label=dev&include_prereleases)](https://pub.dev/packages/diox)

### Plugins

- cookie_manager: [link](plugins/cookie_manager)
[![Pub](https://img.shields.io/pub/v/dio_cookie_manager.svg?label=dev&include_prereleases)](https://pub.dev/packages/dio_cookie_manager)
[![Pub](https://img.shields.io/pub/v/diox_cookie_manager.svg?label=dev&include_prereleases)](https://pub.dev/packages/diox_cookie_manager)
- http2_adapter: [link](plugins/http2_adapter)
[![Pub](https://img.shields.io/pub/v/dio_http2_adapter.svg?label=dev&include_prereleases)](https://pub.dev/packages/dio_http2_adapter)
[![Pub](https://img.shields.io/pub/v/diox_http2_adapter.svg?label=dev&include_prereleases)](https://pub.dev/packages/diox_http2_adapter)

### Examples

Expand Down
4 changes: 2 additions & 2 deletions dio/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@

- Improve `DioError`s. There are now more cases in which the inner original stacktrace is supplied.
- `HttpClientAdapter` must now be implemented instead of extended.
- Any classes specific to `dart:io` platforms can now be imported via `import 'package:dio/io.dart';`.
Classes specific to web can be imported via `import 'package:dio/browser.dart';`.
- Any classes specific to `dart:io` platforms can now be imported via `import 'package:diox/io.dart';`.
Classes specific to web can be imported via `import 'package:diox/browser.dart';`.
- `connectTimeout`, `sendTimeout`, and `receiveTimeout` are now `Duration`s.

## 4.0.6
Expand Down
34 changes: 17 additions & 17 deletions dio/README-ZH.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ dependencies:
## 一个极简的示例
```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';

final dio = Dio();

Expand All @@ -79,17 +79,17 @@ void getHttp() async {

### 相关插件

| 仓库 | 最新版本 | 描述 |
|----------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------|
| [dio_cookie_manager](https://github.com/flutterchina/dio/tree/master/plugins/cookie_manager) | [![Pub](https://img.shields.io/pub/v/dio_cookie_manager.svg)](https://pub.flutter-io.cn/packages/dio_cookie_manager) | Cookie 管理 |
| [dio_http2_adapter](https://github.com/flutterchina/dio/tree/master/plugins/http2_adapter) | [![Pub](https://img.shields.io/pub/v/dio_http2_adapter.svg)](https://pub.flutter-io.cn/packages/dio_http2_adapter) | 支持 HTTP/2 的自定义适配器 |
| [dio_smart_retry](https://github.com/rodion-m/dio_smart_retry) | [![Pub](https://img.shields.io/pub/v/dio_smart_retry.svg)](https://pub.flutter-io.cn/packages/dio_smart_retry) | 支持灵活地请求重试 |
| [http_certificate_pinning](https://github.com/diefferson/http_certificate_pinning) | [![Pub](https://img.shields.io/pub/v/http_certificate_pinning.svg)](https://pub.flutter-io.cn/packages/http_certificate_pinning) | 用于 Flutter 的 HTTPS 证书锁定 |
| [curl_logger_dio_interceptor](https://github.com/OwnWeb/curl_logger_dio_interceptor) | [![Pub](https://img.shields.io/pub/v/curl_logger_dio_interceptor.svg)](https://pub.flutter-io.cn/packages/curl_logger_dio_interceptor) | 用于 Flutter 的 CURL 命令生成器 |
| [dio_cache_interceptor](https://github.com/llfbandit/dio_cache_interceptor) | [![Pub](https://img.shields.io/pub/v/dio_cache_interceptor.svg)](https://pub.flutter-io.cn/packages/dio_cache_interceptor) | 具有多个符合 HTTP 指令的 HTTP 缓存拦截器, |
| [dio_http_cache](https://github.com/hurshi/dio-http-cache) | [![Pub](https://img.shields.io/pub/v/dio_http_cache.svg)](https://pub.flutter-io.cn/packages/dio_http_cache) | 类似 Android 中的 RxCache 的缓存管理 |
| [pretty_dio_logger](https://github.com/Milad-Akarie/pretty_dio_logger) | [![Pub](https://img.shields.io/pub/v/pretty_dio_logger.svg)](https://pub.flutter-io.cn/packages/pretty_dio_logger) | 基于拦截器的简明易读的请求日志打印 |
| [native_dio_client](https://github.com/ueman/native-dio-client) | [![Pub](https://img.shields.io/pub/v/native_dio_client.svg)](https://pub.flutter-io.cn/packages/native_dio_client) | 使用 cupertino_http 和 cronet_http 以适配器代理实现的原生网络请求功能。 |
| 仓库 | 最新版本 | 描述 |
|--------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------|
| [diox_cookie_manager](https://github.com/cfug/diox/blob/main/plugins/cookie_manager) | [![Pub](https://img.shields.io/pub/v/diox_cookie_manager.svg)](https://pub.flutter-io.cn/packages/diox_cookie_manager) | Cookie 管理 |
| [diox_http2_adapter](https://github.com/cfug/diox/blob/main/plugins/http2_adapter) | [![Pub](https://img.shields.io/pub/v/diox_http2_adapter.svg)](https://pub.flutter-io.cn/packages/diox_http2_adapter) | 支持 HTTP/2 的自定义适配器 |
| [dio_smart_retry](https://github.com/rodion-m/dio_smart_retry) | [![Pub](https://img.shields.io/pub/v/dio_smart_retry.svg)](https://pub.flutter-io.cn/packages/dio_smart_retry) | 支持灵活地请求重试 |
| [http_certificate_pinning](https://github.com/diefferson/http_certificate_pinning) | [![Pub](https://img.shields.io/pub/v/http_certificate_pinning.svg)](https://pub.flutter-io.cn/packages/http_certificate_pinning) | 用于 Flutter 的 HTTPS 证书锁定 |
| [curl_logger_dio_interceptor](https://github.com/OwnWeb/curl_logger_dio_interceptor) | [![Pub](https://img.shields.io/pub/v/curl_logger_dio_interceptor.svg)](https://pub.flutter-io.cn/packages/curl_logger_dio_interceptor) | 用于 Flutter 的 CURL 命令生成器 |
| [dio_cache_interceptor](https://github.com/llfbandit/dio_cache_interceptor) | [![Pub](https://img.shields.io/pub/v/dio_cache_interceptor.svg)](https://pub.flutter-io.cn/packages/dio_cache_interceptor) | 具有多个符合 HTTP 指令的 HTTP 缓存拦截器, |
| [dio_http_cache](https://github.com/hurshi/dio-http-cache) | [![Pub](https://img.shields.io/pub/v/dio_http_cache.svg)](https://pub.flutter-io.cn/packages/dio_http_cache) | 类似 Android 中的 RxCache 的缓存管理 |
| [pretty_dio_logger](https://github.com/Milad-Akarie/pretty_dio_logger) | [![Pub](https://img.shields.io/pub/v/pretty_dio_logger.svg)](https://pub.flutter-io.cn/packages/pretty_dio_logger) | 基于拦截器的简明易读的请求日志打印 |
| [native_dio_client](https://github.com/ueman/native-dio-client) | [![Pub](https://img.shields.io/pub/v/native_dio_client.svg)](https://pub.flutter-io.cn/packages/native_dio_client) | 使用 cupertino_http 和 cronet_http 以适配器代理实现的原生网络请求功能。 |

### 相关的项目

Expand All @@ -101,7 +101,7 @@ void getHttp() async {
发起一个 `GET` 请求 :

```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';
final dio = Dio();
Expand Down Expand Up @@ -398,7 +398,7 @@ dio.interceptors.add(
一个简单的自定义拦截器示例:

```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';
class CustomInterceptors extends Interceptor {
@override
void onRequest(RequestOptions options, RequestInterceptorHandler handler) {
Expand Down Expand Up @@ -743,7 +743,7 @@ void initAdapter() {

## HTTP/2 支持

[dio_http2_adapter](../plugins/http2_adapter) 提供了一个支持 HTTP/2 的桥接 。
[diox_http2_adapter](../plugins/http2_adapter) 提供了一个支持 HTTP/2 的桥接 。

## 请求取消

Expand Down Expand Up @@ -772,8 +772,8 @@ token.cancel('cancelled');
但是可以继承 `DioForNative``DioForBrowser`

```dart
import 'package:dio/dio.dart';
import 'package:dio/native_imp.dart';
import 'package:diox/dio.dart';
import 'package:diox/native_imp.dart';
// 在浏览器中,导入 'package:dio/browser.dart'。
class Http extends DioForNative {
Expand Down
18 changes: 9 additions & 9 deletions dio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ The latest version including pre-releases is: ![Pub](ttps://img.shields.io/pub/v
### Super simple to use
```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';

final dio = Dio();

Expand All @@ -85,8 +85,8 @@ void getHttp() async {

| Repository | Status | Description |
|--------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------|
| [dio_cookie_manager](../plugins/cookie_manager) | [![Pub](https://img.shields.io/pub/v/dio_cookie_manager.svg)](https://pub.dev/packages/dio_cookie_manager) | A cookie manager for Dio |
| [dio_http2_adapter](../plugins/http2_adapter) | [![Pub](https://img.shields.io/pub/v/dio_http2_adapter.svg)](https://pub.dev/packages/dio_http2_adapter) | A Dio HttpClientAdapter which support Http/2.0 |
| [diox_cookie_manager](../plugins/cookie_manager) | [![Pub](https://img.shields.io/pub/v/diox_cookie_manager.svg)](https://pub.dev/packages/diox_cookie_manager) | A cookie manager for Dio |
| [diox_http2_adapter](../plugins/http2_adapter) | [![Pub](https://img.shields.io/pub/v/diox_http2_adapter.svg)](https://pub.dev/packages/diox_http2_adapter) | A Dio HttpClientAdapter which support Http/2.0 |
| [dio_smart_retry](https://github.com/rodion-m/dio_smart_retry) | [![Pub](https://img.shields.io/pub/v/dio_smart_retry.svg)](https://pub.dev/packages/dio_smart_retry) | Flexible retry library for Dio |
| [http_certificate_pinning](https://github.com/diefferson/http_certificate_pinning) | [![Pub](https://img.shields.io/pub/v/http_certificate_pinning.svg)](https://pub.dev/packages/http_certificate_pinning) | Https Certificate pinning for Flutter |
| [curl_logger_dio_interceptor](https://github.com/OwnWeb/curl_logger_dio_interceptor) | [![Pub](https://img.shields.io/pub/v/curl_logger_dio_interceptor.svg)](https://pub.dev/packages/curl_logger_dio_interceptor) | A Flutter curl-command generator for Dio. |
Expand All @@ -105,7 +105,7 @@ in [here](https://github.com/flutterchina/dio/issues/347).
Performing a `GET` request:

```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';
final dio = Dio();
Expand Down Expand Up @@ -425,7 +425,7 @@ dio.interceptors.add(
Simple interceptor example:

```dart
import 'package:dio/dio.dart';
import 'package:diox/dio.dart';
class CustomInterceptors extends Interceptor {
@override
void onRequest(RequestOptions options, RequestInterceptorHandler handler) {
Expand Down Expand Up @@ -787,7 +787,7 @@ so it's not recommended to use in common cases.

## HTTP/2 support

[dio_http2_adapter](../plugins/http2_adapter) is a Dio `HttpClientAdapter`
[diox_http2_adapter](../plugins/http2_adapter) is a Dio `HttpClientAdapter`
which supports HTTP/2.

## Cancellation
Expand Down Expand Up @@ -818,9 +818,9 @@ so we don't extend `Dio` class direct.
We can extend `DioForNative` or `DioForBrowser` instead, for example:

```dart
import 'package:dio/dio.dart';
import 'package:dio/io.dart';
// If in browser, import 'package:dio/browser.dart'.
import 'package:diox/dio.dart';
import 'package:diox/io.dart';
// If in browser, import 'package:diox/browser.dart'.
class Http extends DioForNative {
Http([BaseOptions options]) : super(options) {
Expand Down
Loading

0 comments on commit 09e6f9b

Please sign in to comment.