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

我如何定义不同状态的缺省页来显示 #15

Closed
liangjingkanji opened this issue Jan 8, 2022 · 0 comments
Closed

我如何定义不同状态的缺省页来显示 #15

liangjingkanji opened this issue Jan 8, 2022 · 0 comments

Comments

@liangjingkanji
Copy link
Owner

liangjingkanji commented Jan 8, 2022

默认情况下只支持四种状态

  • 加载中
  • 错误
  • 内容

但是每个状态的显示函数show**(tag:Any?)支持传递任意对象参数. 你可以在缺省页生命周期函数中根据tag不同创建不同的视图以及逻辑代码

StateChangedHandler缺省页处理者或者on**()等函数都能获得tag. 这样你就可以定义无数状态的缺省页了

比如错误缺省页常常分为无网络或接口错误, 或者展示错误信息, 本框架都支持

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

No branches or pull requests

1 participant