Open
Description
Description
Following the code from https://elmish.github.io/react/native.html does not compile
Repro code
steps
- create
paket.dependencies
from https://github.com/elmish/react/blob/v3.x/paket.dependencies dotnet new fable
dotnet tool install paket
- and remove the nuget references insideApp.fsproj
dotnet paket convert-from-nuget --force
- manually add the files from
paket.dependencies
topaket.references
dotnet paket install
npm install
npm start
-> runs just fine- change the App.fs to match the Fable React Elmish sample code -> No Compilation
fable-elmish-react-fail.zip
source https://nuget.org/api/v2
storage: none
nuget Fable.Browser.Dom 2.2.0
nuget Fable.Elmish.React
nuget FSharp.Core redirects:force, content:none
nuget Fable.Core 3.2.3
nuget Fable.React
nuget Fable.Elmish
paket.references
Fable.Browser.Dom
Fable.Elmish.React
FSharp.Core
Fable.Core
Fable.React
Fable.Elmish
Expected and actual results
Expected dotnet build
and npm start
still work
Actual
Description
Following the code from https://elmish.github.io/react/native.html does not compile
Repro code
steps
- create
paket.dependencies
from https://github.com/elmish/react/blob/v3.x/paket.dependencies - add
Fable.React.Elmish
dotnet new fable
dotnet tool install paket
dotnet paket convert-from-nuget --force
- manually add the files from
paket.dependencies
topaket.references
paket install
npm install
npm start
-> runs just fine- change the App.fs to match the Fable React Elmish sample code -> No Compilation
source https://nuget.org/api/v2
storage: none
nuget Fable.Elmish.React
nuget FSharp.Core redirects:force, content:none
nuget Fable.Core
nuget Fable.React
nuget Fable.Elmish
paket.references
FSharp.Core
Fable.Core
Fable.React
Fable.Elmish
Fable.Elmish.React
Expected and actual results
Expected dotnet build
and npm start
still work
Actual
Neither works, both complain about missing namespaces
>dotnet build
Microsoft (R) Build Engine version 16.9.0+57a23d249 for .NET
Copyright (C) Microsoft Corporation. All rights reserved.
Determining projects to restore...
Paket version 5.257.0
The last restore is still up to date. Nothing left to do.
Performance: - Runtime: 120 milliseconds
Paket version 5.257.0
Starting restore process.
Performance: - Runtime: 784 milliseconds
Restored D:\projects\insertprojectnamehere\App.fsproj (in 147 ms).
D:\projects\insertprojectnamehere\App.fs(16,19): error FS0039: The namespace 'ReactNative' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(17,12): error FS0039: The namespace 'Helpers' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(21,5): error FS0039: The value or constructor 'text' is not defined. Maybe you want one of the following:↔ Text↔ exn↔ exp↔ exn [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(27,8): error FS0039: The value or constructor 'touchableHighlightWithChild' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(40,5): error FS0039: The value or constructor 'view' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
Build FAILED.
D:\projects\insertprojectnamehere\App.fs(16,19): error FS0039: The namespace 'ReactNative' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(17,12): error FS0039: The namespace 'Helpers' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(21,5): error FS0039: The value or constructor 'text' is not defined. Maybe you want one of the following:↔ Text↔ exn↔ exp↔ exn [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(27,8): error FS0039: The value or constructor 'touchableHighlightWithChild' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
D:\projects\insertprojectnamehere\App.fs(40,5): error FS0039: The value or constructor 'view' is not defined. [D:\projects\insertprojectnamehere\App.fsproj]
0 Warning(s)
5 Error(s)
Time Elapsed 00:00:04.11
Related information
- elmish version: 3.1 (Fable.Elmish.React 3.0.1)
- fable-compiler version: where is this stored?
- fable-core version: Fable.Core 3.2.7
- Operating system: Windows 10