Fable
Fable copied to clipboard
Question about compile time file ordering of dependent fable nuget packages
Description
I have a fable compatible nuget packages Constants
and Library
where Library
depends on Constants
.
When I add package reference to Library in our SPA app and compile it with fable I get F# compiler error while compiling sources of Library
that the namespace of Constants
is not known.
I executed fable compiler with --verbose flag and have seen that the source files of Library
come before the source files of Constants
. Both of the package sources can be found in fable_modules so I guess the dependencies resolved correctly.
Can I somehow influence the compile time ordering of files from fable_modules? Am I doing something wrong? How does the Fable order the files from referenced fable nuget packages?
Expected and actual results
I would expect the fable compiler to respect the nuget package dependencies order and sort the files when compiling accordingly. In my case first all the files from Constants
should be compiled before the files of Library
and at the and the files from the SPA app.
Related information
- Fable version: 4.18.0
- Operating system: windows 11