Open ImaginaryDevelopment opened 3 years ago
Sadly RN story has been neglected and I don't see myself updating it. A new sample needs to be built from scratch using the latest RN tooling and current Fable compiler (this sample was written for Fable 2.x). Not sure how well the two still fit together. PR would be welcome.
That's unfortunate, could you point me in the right direction?
On Tue, Jun 8, 2021 at 3:43 PM Eugene Tolmachev @.***> wrote:
Sadly RN story has been neglected and I don't see myself updating it. A new sample needs to be built from scratch using the latest RN tooling and current Fable compiler (this sample was written for Fable 2.x). Not sure how well the two still fit together. PR would be welcome.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/elmish/react/issues/52#issuecomment-857059613, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA5TPCXMQ2I3VNZT72ZXEDTRZXHDANCNFSM46KGWAWQ .
Hello @ImaginaryDevelopment with Fable 3 it is now easier to integrate Fable into JavaScript tooling because Fable 3 generates JavaScript files directly on the disk.
If the standard JavaScript workflow is:
Now with Fable it is:
It removes the needs to have custom loader or plugin for the JavaScript tools.
Knowing that, setting up Fable looks like that:
dotnet new tool-manifest
dotnet tool install fable
Run dotnet fable <path to your fsproj proj> --watch
this will generate the the files along side the F# files.
If you prefer to have them in their own folder, you can use dotnet fable <path to your fsproj proj> --watch --outDir fableBuild
, this will place the generated files into the fableBuild
directory
Description
Following the code from https://elmish.github.io/react/native.html does not compile
Repro code
steps
paket.dependencies
from https://github.com/elmish/react/blob/v3.x/paket.dependenciesdotnet new fable
dotnet tool install paket
- and remove the nuget references insideApp.fsproj
dotnet paket convert-from-nuget --force
paket.dependencies
topaket.references
dotnet paket install
npm install
npm start
-> runs just finepaket.references
Expected and actual results
Expected
dotnet build
andnpm start
still workActual
Description
Following the code from https://elmish.github.io/react/native.html does not compile
Repro code
steps
paket.dependencies
from https://github.com/elmish/react/blob/v3.x/paket.dependenciesFable.React.Elmish
dotnet new fable
dotnet tool install paket
dotnet paket convert-from-nuget --force
paket.dependencies
topaket.references
paket install
npm install
npm start
-> runs just finepaket.references
Expected and actual results
Expected
dotnet build
andnpm start
still workActual
Neither works, both complain about missing namespaces
Related information