Closed omcnoe closed 2 years ago
But please keep in mind this project is very young and in beta, so there are some bugs or even breaking changes. Thanks for you feedback. :)
I have all the necesary packages in the .fsproj
<PackageReference Include="Fun.Blazor.Elmish" Version="2.0.0-beta*" />
<PackageReference Include="Fun.Blazor.HtmlTemplate" Version="2.0.0-beta008" />
<PackageReference Include="Fun.Blazor.Wasm" Version="2.0.0-beta*" />
And my code does open the necessary modules. Sorry just got cropped out of the example.
I think it is an actual bug if init Cmd is Cmd.none
:) Understood that project is in beta.
Sorry I misunderstanded your point. I can reproduce that now. It is here: https://github.com/slaveOftime/Fun.Blazor/blob/29068b94fae0974323399ae116c4b729c24e4244/Fun.Blazor.Elmish/ElmComponent.fs#L31-L44 I will check how elmish work again and try to fix it. If you are very familiar with elmish your help will be very welcomed :)
@omcnoe hi, I changed the init a little bit. The bug should be fixed.
But I will lerarn more on elmish to improve it when I got more time.
Yes, issue is fixed. Thanks.
The first state update is discarded, unless you use the
html.elmish
constructor that includes an initialCmd<Msg>
, AND theMsg
is not a noop.Fun.Blazor.Wasm 2.0.0-beta008
Simple repro: