@fossa-app/bridge
v0.1.26
Published
Shared Domain Models and DTOs for Fossa UI and API
Readme
FossaApp Bridge
The FossaApp Bridge provides shared frontend and backend functionality.
Project Purpose
The Fossa.Bridge project is a shared F# library designed to encapsulate logic, validation, and domain models that are common to both the .NET backend and the TypeScript/JavaScript frontend. By using Fable, the F# code is transpiled into JavaScript/TypeScript for the frontend environment while simultaneously being compiled into a standard .NET library for the backend. This ensures a single source of truth for core business logic, API models, and data validation rules, reducing duplication and preventing synchronization issues between the client and server.
Package Usage
For .NET Backends (C# / F#)
Install the NuGet package:
dotnet add package Fossa.BridgeFor JavaScript / TypeScript Frontends
Install the NPM package:
npm install @fossa-app/bridgeor using Yarn:
yarn add @fossa-app/bridgeFeatures
- Shared API domain models.
- Common validation and helper logic.
- Consistent behavior across client and server.
Building and Packaging
To build both NPM and NuGet packages locally, run the included PowerShell script:
.\pack.ps1