Open frybin opened 2 years ago
@frybin we do not maintain the typescript for Relay. You probably need to update something here: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/relay-runtime
Just ran into this as well. I think the team should actively maintain these types.
I know you only care about Flow at Meta, but I would say Typescript is definitely the open-source standard nowadays. At least I haven't seen a React project without Typescript in a while.
If the team wants to improve the open-source Relay experience, I think this is definitely one area to start!
EDIT: Although in this specific case, there's a 3rd party library for the subscriptions involved - so it might be that you guys can't even do anything.
When following the example on how to set up the network layer to handle subscriptions from the docs site I am receiving multiple errors trying to set up the network layer in a
create-react-app
app initialized in typescript.The first Error I get is.
I was able to solve this issue by changing
to
And now the issue I am getting is:
Below are the contents of the file where I am trying to set up the network layer.