Problems after installing .Net SDK 7
DejanMilicic opened this issue · 4 comments
After installing .Net 7 SDK, code that was working fine before
let adjectivesApi =
Remoting.createApi ()
|> Remoting.withRouteBuilder Route.builder
|> Remoting.buildProxy<IAdjectivesApi>
is now producing following error
Uncaught Error: Option has no value
at value (Option.js:39:15)
at Remoting_buildProxy_Z2B50D2A3 (Remoting.fs.js:60:26)
I solved it by upgrading from 7.21 to 7.24
That's caused by upgrading to Fable 4, but yes, newer client versions fixed it.
Actually, I tried both with 3.7.18 and 4.0.0-theta-018 and results was the same.
For some reason, the mere act of installing SDK 7 broke my project, even thought I did not change anything in the project itself (and I was compiling using 3.7.18)
That's weird, because https://github.com/Zaid-Ajaj/Fable.Remoting/pull/313/files fixed that specific error message (caused by missing ITypeResolver
in Fable 4) in v7.22. I've been on .NET 7 since Preview 1 with Fable 3 and had no problems with Remoting, and I would be surprised if a different SDK version used to build the client started causing runtime exceptions in JS.
As long as your application now works reliably, none of this really matters.