Skip to content

rfrerebe/Fable.Import.SignalRCore

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fable.Fable.Fable.Import.SignalRCore

How to use this templates ?

  1. Add your code into src folder.
  2. Add your test into tests folder. All the tests are run against mocha
  3. You can now run build.cmd MochaTest. This is build the lib for you and run the tests.

Building

Make sure the following requirements are installed in your system:

Then you just need to type ./build.cmd or ./build.sh

Release

In order to push your package to [nuget.org][https://nuget.org] you need to add your API keys to NUGET_KEY environmental variable. You can create a key here.

#### 0.2.0 - 30.04.2017
* FEATURE: Does cool stuff!
* BUGFIX: Fixes that silly oversight
  • You can then use the Release target. This will:
    • make a commit bumping the version: Bump version to 0.2.0
    • publish the package to nuget
    • push a git tag

./build.sh Release

MacOS/Linux Windows
Travis Badge Build status
Build History Build History

Nuget

Stable Prerelease
NuGet Badge NuGet Badge

A note about Fable Libraries vs Fable Bindings

There are two kinds of Fable packages:

  • JS Bindings: These don't contain any actual code, only signatures and attributes normally generated by ts2fable. They're just used to provide a type-safe to interact with a JS library from Fable.
  • Libraries: These contain F# code that will be compiled to JS by Fable when being referenced by a consumer project.

The distinction is important because Fable can read metadata from .dll assemblies (like signatures and attributes) but not executable code, for that it needs the F# sources. For JS bindings without actual code you don't need to worry as they can be distributed as any other Nuget package. However, Fable libraries need a couple of extra steps:

  • First, the package must contain a folder named fable with the F# sources (and if necessary other files like JS scripts).
  • The fable folder must contain an .fsproj file with the same name as the Nuget package.

This is not difficult to do and usually only requires adding a tag to your project file (example), but you need to make sure all the sources get into the package with the proper directory structure. Also, take into account Fable will just make a simple XML parsing to extract the source files from the .fsproj, so you should avoid MSBuild conditionals, etc.

Because Fable will compile your sources you must be careful with compiler directives too (like #if MY_SYMBOL, etc). Though you can use this to your advantage and do some logging in debug mode (#if DEBUG). And remember also that Fable will always define the FABLE_COMPILER symbol when compiling to JS.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published