Comments (5)
这是 Dio 2.0 的示例,请将示例中的 flipper_dio_interceptor.dart 文件添加到你的项目
https://github.com/blankapp/flutter_flipperkit/blob/master/example/lib/networking/api_client/api_client.dart
BaseOptions options = new BaseOptions(
baseUrl: 'https://www.v2ex.com/api',
connectTimeout: 5000,
receiveTimeout: 3000,
headers: {
"Accept": "application/json",
"Content-Type": "application/json"
},
responseType: ResponseType.json,
);
this._http = new Dio(options);
// 添加 FlipperDioInterceptor 拦截器
this._http.interceptors.add(FlipperDioInterceptor());
from flutter_flipperkit.
只有使用dio做为网络请求客户端的时候 才能用吗?
from flutter_flipperkit.
@zakiso flutter_flipperkit
(将在 0.0.7 中发布该功能,请留意版本更新) 已支持全局拦截网络请求(所有基于 HttpClient
API 的请求均可被拦截),如果你未设置网络插件 useHttpOverrides
参数为 false,则无需使用该拦截器。
如果其他网络请求库无法被自动拦截,则可能参考 Dio 的实现。
https://github.com/blankapp/flutter_flipperkit_plugins/tree/master/packages/flipperkit_dio_interceptor
如有疑问可加入电报群 https://t.me/flutterdebugger 提问。
from flutter_flipperkit.
👍 期待新版本
from flutter_flipperkit.
@zakiso Flutter Debugger 已经发布,
下载:https://github.com/blankapp/flutter-debugger/releases/
文档:https://flutter-debugger.blankapp.org/
from flutter_flipperkit.
Related Issues (20)
- How to set up with new style settings.gradle file on Android? HOT 1
- New pod format support HOT 2
- [Flutter v1.22] Cannot build HOT 2
- Error building iOS app after Flutter (1.22.1) upgrade HOT 13
- Plugins seem to not be working on flipper 0.72.0 HOT 3
- Not able to Build iOS default flutter app HOT 2
- Upgrade to uuid ^3.0.1 HOT 1
- Not working with --profile flag HOT 4
- fatal error: 'boost/preprocessor/control/expr_iif.hpp' file not found HOT 1
- Watchman: Watchman was not found in PATH. See https://facebook.github.io/watchman/docs/install.html for installation instructions HOT 2
- iOS error when building as static library HOT 8
- symbol(s) not found for architecture x86_64 HOT 1
- Can't build Android with Gradle Build Tools 4.2.1 HOT 3
- Conflict with other dependencies HOT 2
- HttpClient的签名发生了改变 HOT 1
- ios 启动报错 HOT 3
- How to mock network in flutter using flipper
- Project run throws " The non-abstract class 'FlipperHttpClient' is missing implementations " HOT 2
- Use of bitwise '|' with boolean operands | XCode 14.3 fails builds using Yoga, If there is a need to use an old version Yoga, an older version of XCode is required.
- CKNonNull.h:47:33 No member named 'move' in namespace 'std'; did you mean 'modf'?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flutter_flipperkit.