⚡
On-demand CLR binding
CSharp / csharp: lazy binding and shared calling bridges with consistent overload and marshaling rules; no business-maintained per-type Wrap allowlist.
🟦
TypeScript and debugging
TsProject checks, emit, CLR declarations, and source maps, with built-in V8 Inspector in the Editor.
📦
Native V8 and HostJs
Official static V8 on native platforms; platform VMs on WebGL/WeChat. Library SDKs support read-only Git packages.
Bidirectional calls at a glance
- C# → JS
- JS/TS → C#
// Bootstrap
JsAppDomain.Initialize(JsFileModuleLoader.Load);
void Start()
{
var add = JsAppDomain.GetFunction<Func<int, int, int>>("app", "add");
Debug.Log(add(10, 20)); // 30
}// TsProject/out/app.js (canonical: "app")
export function add(a, b) {
return a + b;
}import { Demo } from "csharp:Assembly-CSharp";
const d = new Demo();
d.x = 10;
console.log("Add:", Demo.Add(3, 5));