Emit C# strongly typed interface code from TypeScript definition files.
Перейти к файлу
Kenneth Pouncey 7018666b67
Merge pull request #5 from hosezelt/UpdateToTsMorph
Update to ts morph
2019-08-02 07:44:53 +02:00
.vscode Add support for TypeQuery nodes. 2018-03-19 10:08:12 +01:00
docs Add support for constructor parameter definitions. 2018-02-26 14:01:48 +01:00
src Fix to make tests pass 2019-03-01 20:29:09 +01:00
test Update test cases to pass with current generation. 2018-10-29 11:06:00 +01:00
.gitignore Initial Import 2018-02-10 08:48:16 +01:00
LICENSE.md Create LICENSE.md 2018-02-14 04:51:00 +01:00
README.md Update README.md 2018-03-26 08:38:31 -04:00
package-lock.json Merge pull request #5 from hosezelt/UpdateToTsMorph 2019-08-02 07:44:53 +02:00
package.json Update dependency to ts-morph 2019-03-01 20:07:24 +01:00
tsconfig.json Add support for multiple Heritage of interfaces to class generation. 2018-03-02 17:22:37 +01:00
tslint.json Initial Import 2018-02-10 08:48:16 +01:00

README.md

TsToCSharp

Emit C# strongly typed interface code from TypeScript definition files.

This project is intended to read in TypeScript (.d.ts) defintions files and generate as closely as possible a C# strongly typed API for use from either WebAssembly code or .NET hosted in Electron.

Current Work

This is a work in progress, and we are only getting started.

Only the very basic TypeScript AST parsing is present at this time. Mostly the basic types like interface, boolean, number, arrays, properties, methods and a handful of there associated complex types like string | null, number | null, boolean | null etc.

Getting Started

  1. Installing
  2. Usage
  3. TypeScript to C# mapping
  4. Examples
  5. Unit Tests

Obtaining Definition files

Definitions files describe the shape of JavaScript to the TypeScript compiler and are used only to compile.

The Definitely Typed github repository contains a large collection of TypeScript type definitions (.d.ts).

Suggested resources on Definition Files