Typing problem with schemas and TypeScript #140
laaketeknikko
started this conversation in
General
Replies: 1 comment
-
OK! I can take a look at this. Do you have a small repo I can fork to make it work for you? And thanks for the feedback overall! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am creating the store as follows, using React and the provider:
Schemas:
TypeScript gives me the following error on the store:
If I import from tinybase/debug/ui-react/with-schemas, TypeScript tells me there's no Provider.
Elsewhere I am doing:
it sets the value and I get no TypeScript errors. It reads the value and I get no TypeScript errors. So, it works, as far as I'm aware, and TypeScript gives no grief in the actual usage.
What I am going wrong?
Using TypeScript 5.4.2 and tinybase 4.7.1
As an aside, I have to say the setup for this library is quite convoluted for TypeScript + React, at least as a beginner programmer. It honestly took me many hours. I did not start from the template, though. But, when it's all done, it's quite simple really, so it might just be the documentation.
Beta Was this translation helpful? Give feedback.
All reactions