fable-react icon indicating copy to clipboard operation
fable-react copied to clipboard

Last Fable.React upgrade breaks my code

Open OnurGumus opened this issue 3 years ago • 7 comments

image

I guess screenshot says all. Any ideas?

OnurGumus avatar Sep 11 '22 20:09 OnurGumus

I was using Lit sample by the way

OnurGumus avatar Sep 11 '22 20:09 OnurGumus

We're trying to split React types and helpers in two different libraries (see discussion). The idea is we can have different React APIs (original React, Feliz, incoming JSX, etc..) to be compatible with each other without having to depend on the full Fable.React. But unfortunately this breaks code if you're depending on a library that hasn't been updated, because F# doesn't support type forwarding.

What are the other React dependencies in your project? In any case you probably don't need to update right now.

alfonsogarciacaro avatar Sep 12 '22 14:09 alfonsogarciacaro

I understand. In that case I will stick to older version. Feel free to close the issue if you will.

OnurGumus avatar Sep 12 '22 15:09 OnurGumus

Does this mean we have to pin ~> 8 until every single library we're referencing has switched?

kerams avatar Sep 15 '22 09:09 kerams

And conversely, if I create a new bindings package and use Fable.React.Types, I can't use it if I also reference packages that haven't switched?

kerams avatar Sep 16 '22 17:09 kerams

Would it be possible to release a new beta of Elmish.React which uses Fable.React.Types, so that Fulma and its extensions could in turn upgrade to it as well? That would unblock the upgrade path to Fable.React 9 (and Fable 4) in my project at least.

cc @MangelMaxime

kerams avatar Sep 19 '22 09:09 kerams

And conversely, if I create a new bindings package and use Fable.React.Types, I can't use it if I also reference packages that haven't switched?

Yes, this is very unfortunate because F# doesn't support type forwarding. The funny thing is it does work in Fable because we always compile the sources, but having errors in the IDE is not nice. Let's try to update all packages quickly so we can make the pain short-lived :)

Would it be possible to release a new beta of Elmish.React which uses Fable.React.Types, so that Fulma and its extensions could in turn upgrade to it as well? That would unblock the upgrade path to Fable.React 9 (and Fable 4) in my project at least.

Elmish.React has just been released :tada:

alfonsogarciacaro avatar Sep 20 '22 02:09 alfonsogarciacaro