Closed Arnarkari93 closed 2 years ago
Hey, sorry for the slow reply. I'll take a look at this soon, but before I do, have you considered just writing a simple binding typed in the way you use it rather than trying to represent all the dynamic props?
Isn't going to be an issue that rescript Apollo client is extended and defines a method rescript_query
? I can't just make a simple binding for mockedProvider and say it is ApolloClient.t
Ah, yes, sorry. I only used MockedProvider
for a short while a long time ago and thought I remembered you being able to provide a client. This may be a pretty serious consequence of having gone the route of representing objects as records rather than keeping every method as a separate function.
I'm not sure the best way to proceed here. On the one hand, MockedProvider
seems dead simple. It's mostly a convenience function for creating a client using MockLink
and some teardown. Maybe just recreate it in rescript?
Thoughts?
Sorry for the late response. Yes, I think recreating it in rescript is a good solution. I don't think I will be working with this library anytime soon, but If I do, I will check it out.
How would we approach writing bindings for
MockedProvider
? Themocks
prop is so dynamic and I am struggling where to begin. Has anybody thought about this?