https://github.com/elringus/bootsharp
Compile C# solution into single-file ES module with auto-generated JavaScript bindings and type definitions
https://github.com/elringus/bootsharp
bun codegen csharp deno interop js node ts typescript wasm
Last synced: 27 days ago
JSON representation
Compile C# solution into single-file ES module with auto-generated JavaScript bindings and type definitions
- Host: GitHub
- URL: https://github.com/elringus/bootsharp
- Owner: elringus
- License: mit
- Created: 2021-11-12T18:43:18.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-09-23T17:17:24.000Z (7 months ago)
- Last Synced: 2024-10-29T17:28:18.482Z (6 months ago)
- Topics: bun, codegen, csharp, deno, interop, js, node, ts, typescript, wasm
- Language: C#
- Homepage: https://bootsharp.com
- Size: 3.74 MB
- Stars: 667
- Watchers: 15
- Forks: 36
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
Awesome Lists containing this project
README
# Use C# in web apps with comfort
Bootsharp streamlines the integration of .NET C# apps and libraries into web projects. It's ideal for building applications where the domain (backend) is authored in .NET C#, while the UI (frontend) is a standalone TypeScript or JavaScript project. Think of it as [Embind](https://emscripten.org/docs/porting/connecting_cpp_and_javascript/embind.html) for C++ or [wasm-bindgen](https://github.com/rustwasm/wasm-bindgen) for Rust.

Facilitating high-level interoperation between C# and TypeScript, Bootsharp lets you build the UI layer within its natural ecosystem using industry-standard tooling and frameworks, such as [React](https://react.dev) and [Svelte](https://svelte.dev). The project can then be published to the web or bundled as a native desktop or mobile application with [Electron](https://electronjs.org) or [Tauri](https://tauri.app).
## Features
β¨ High-level C# <-> TypeScript interop
π¦ Embeds binaries to single-file ES module
πΊοΈ Works in browsers and JS runtimes (Node, Deno, Bun)
β‘ Generates bindings and types over C# interfaces
π·οΈ Supports interop over object instances
π οΈ Allows customizing emitted bindings
π₯ Supports multi-threading, NativeAOT-LLVM, trimming
## π¬ Get Started
https://bootsharp.com/guide