Fable.Package.SDK 0.1.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package Fable.Package.SDK --version 0.1.0                
NuGet\Install-Package Fable.Package.SDK -Version 0.1.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Fable.Package.SDK" Version="0.1.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Fable.Package.SDK --version 0.1.0                
#r "nuget: Fable.Package.SDK, 0.1.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Fable.Package.SDK as a Cake Addin
#addin nuget:?package=Fable.Package.SDK&version=0.1.0

// Install Fable.Package.SDK as a Cake Tool
#tool nuget:?package=Fable.Package.SDK&version=0.1.0                

Fable.Package.SDK

Fable.Package.SDK is a set of MSBuild targets and tasks that help you build and package Fable projects.

Features 🚀

  • Automatically add Fable specific tags to PackageTags based on the FablePackageType property
  • Automatically include F# source files in the package if needed
  • Check that at least one Fable target is defined in the PackageTags property
  • Set GenerateDocumentationFile to true
  • Set up your package for improving IDE experiences by setting:
    • DebugType to embedded
    • EmbedUntrackedSources to true

Installation

dotnet add package Fable.Package.SDK

Usage

1. Set the FablePackageType property

Set the FablePackageType property in your project file to one of the following values:

  • library: If your package is a library that can be used by Fable.

    Examples of libraries could be Fable.Promise, Elmish, Thoth.Json, Feliz

    [!NOTE] This will include the source files in the package.

  • binding: If your package consist of a set of API to make a native library available

    For example:

    • A package which makes an NPM package API available
    • A package which makes the Browser API available
    • A package which makes a cargo package API available

    [!NOTE] Only the DLL will be included in the package, allowing for a faster build and smaller package size.

2. Specify the targets

Choose one or more of the following tags:

  • fable-dart: Dart is supported by the package
  • fable-dotnet: .NET is supported by the package
  • fable-javascript: JavaScript is supported by the package
  • fable-python: Python is supported by the package
  • fable-rust: Rust is supported by the package
  • fable-all: Package is compatible with all Fable targets.

[!WARNING] A package can be compatible with all targets if it depends only on packages that are also compatible with all targets.

A package compatible with all targets cannot be a binding, as these are target-specific.

Example:

If your package supports only JavaScript you need to use fable-javascript

If your package supports both JavaScript and Python, you need to use fable-javascript and fable-python

Example of use case

If your package is a binding which target JavaScript you need to write:

<PropertyGroup>
    <PackageTags>fable-javascript</PackageTags>
    <FablePackageType>binding</FablePackageType>
</PropertyGroup>

If your package is a library which targets JavaScript and Python you need to write:

<PropertyGroup>
    <PackageTags>fable-javascript;fable-python</PackageTags>
    <FablePackageType>library</FablePackageType>
</PropertyGroup>
There are no supported framework assets in this package.

Learn more about Target Frameworks and .NET Standard.

  • .NETStandard 2.0

    • No dependencies.

NuGet packages (9)

Showing the top 5 NuGet packages that depend on Fable.Package.SDK:

Package Downloads
Fable.Form

Extensible core library used to build forms

Fable.Form.Simple

Contains the global logic of how a form should behave. It can be used has a standalone library if you want to build your own fields or you can use Fable.Form.Simple.Bulma to have a ready to use fields made for Bulma CSS framework.

Fable.Form.Simple.Bulma

Implementation of standard fields using Bulma CSS framework, to be used with Fable.Form.Simple.

Thoth.Json.Core

Elm-inspired encoder and decoder for JSON, this package is the core library which can be used on any F# project. Pick the right additional package for your runtime: - Thoth.Json.JavaScript - Thoth.Json.Python - Thoth.Json.Newtonsoft

Thoth.Json.Newtonsoft

Elm-inspired encoder and decoder for JSON, this package is for .NET runtime when you want to use Newtonsoft.Json.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.0 457 7/27/2024
0.1.0 1,214 6/2/2024