Skip to content

feat: support generics in rxui.ViewModel#293

Merged
CrystalWindSnake merged 5 commits intoCrystalWindSnake:mainfrom
changhe3:feat/viewmodel-generics
May 18, 2025
Merged

feat: support generics in rxui.ViewModel#293
CrystalWindSnake merged 5 commits intoCrystalWindSnake:mainfrom
changhe3:feat/viewmodel-generics

Conversation

@changhe3
Copy link
Contributor

Currently any subclasses of rxui.ViewModel cannot use generic parameters. Add super().__init_subclass__(**kwargs) to support generics.

@changhe3
Copy link
Contributor Author

如果你用的是低版本的python的话,我把test里面的generics改改

@CrystalWindSnake
Copy link
Owner

@changhe3 谢谢你的 PR 🙂 。测试没有通过,测试是基于 python 3.8 的,请修改一下测试中的泛型写法。

@CrystalWindSnake CrystalWindSnake merged commit d5bdd7a into CrystalWindSnake:main May 18, 2025
3 checks passed
@changhe3 changhe3 deleted the feat/viewmodel-generics branch May 18, 2025 22:19
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 this pull request may close these issues.

2 participants