Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

为啥 Dio 工具中展示的网络请求信息要加入 U+200b ? #67

Closed
Tracked by #15
yanni-fe opened this issue Sep 13, 2022 · 2 comments · Fixed by #73
Closed
Tracked by #15

为啥 Dio 工具中展示的网络请求信息要加入 U+200b ? #67

yanni-fe opened this issue Sep 13, 2022 · 2 comments · Fixed by #73

Comments

@yanni-fe
Copy link

What's your question 你遇到了什么问题

在 copy dio 请求数据的时候,发现 copy 出来的数据不能被解析,比如 json 无法直接被格式化等等。
看了下代码发现在展示网络请求信息的时候使用了 \u+200b 这个不可见字符对字符进行了拼接。

我不太理解这个操作的意图,想问下为啥要这么做

TextSpan(text: content.notBreak),
...
extension _StringExtension on String {
  String get notBreak => Characters(this).toList().join('\u{200B}');
}

Environmental info 环境信息

不需要

UME and kits version UME 及插件包版本

flutter_ume_kit_dio 1.0.0

@talisk
Copy link
Member

talisk commented Sep 13, 2022

@AlexV525

@AlexV525
Copy link
Contributor

先前在处理文字的显示时,为了避免文字被过度换行,添加了零宽字符 \u200b 进行处理。后续可以去掉进行直出。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants