Netjs - C# 转成 JavaScript 编译器


未知
跨平台
C#

软件简介

Netjs 是一个 .NET 到 TypeScript 和 JavaScript 的编译器。

该软件目前还有一些限制:

  • 忽略命名空间

  • mscorlib.ts is a tiny subset of the full BCL

  • Overloaded methods generally work, but have trouble with:

    • One overload being virtual and another not (it hurts my head trying to get this to work)

    • Overloads that have the same argument count and accept values that can be null (runtime type checking is used)

    • Overloaded constuctors that call different base constructors probably don’t work

  • Async does not work

  • Gotos only sometimes work

  • Regexes have some problems:

    • Named groups don’t work (we rely on the browser’s regex implementation)

    • Match Group Index only works if you capture everything

  • Integer casts with the expectation of performing a Truncate operation don’t work ()

  • Seriously, watch it with those overloads