surrealdb_flutter
surrealdb_flutter copied to clipboard
Type safety
trafficstars
Hey thanks for your surreal package 📦
I'm currently trying to get my repositories around the package to be type safe. Looking at the other language clients I realize that they always provide a type as interfaces.
It would be awesome to provide a type for serialization/deserialization on the query method. Something like following:
db.query<UserModel>("select * users");
The data model would need to contain a factory fromJson and a toJson method implemented.
What do you think? 💭
Just by writing that, I realized that it might be way more complex that it seems in the first leave due to the nature of the query command. 🫣