Giter Club home page Giter Club logo

dukat's Introduction

Description

Converter of TypeScript definition files to Kotlin declarations

This requires JRE 1.6+ to run. It generates Kotlin files that are compatible with Kotlin 1.1+ (generated declarations are tested against latest stable compiler version)

How to install

The simplest way to use is install the latest version form npm:

npm install -g dukat

Usage

dukat [<options>] <d.ts files>

where possible options include:

    -p  <qualifiedPackageName>      package name for the generated file (by default filename.d.ts renamed to filename.d.kt)
    -m  String                      use this value as @file:JsModule annotation value whenever such annotation occurs
    -d  <path>                      destination directory for files with converted declarations (by default declarations are generated in current directory)
    -v, -version                    print version

How to setup and build

  1. clone this project
# on Windows-based platforms set following: `git config core.autocrlf true`   
git clone <this project url>
  1. build
./gradlew build
  1. (optional) Run unit tests
./gradlew test -Pdukat.test.failure.always

Recent Changes

[0.0.28] - 13'February 2020

  • [descriptors] support for inline and crosslinine modifiers in descriptors
  • [typescript] Inlined invoke extension function can have return type
  • [typescript] Merge vars and interfaces even if they are in different files (but in the same package)
  • [typescript] Merge classlikes correctly (under some conditions they were copied after merge)
  • [typescript] Preserve type params while resolving this return type in extension functions

[0.0.27] - 07'February 2020

  • [build] make it possible to build with arbitrary version of kotlin compiler
  • [build] typescript compiler version updated to 3.5.3
  • [descriptors] support for compiling with 1.3.70-eap-42
  • [typescript] Move top level declarations into a separate file whenever it's invalid to keep them with the rest of declarations (that is, when there's file-level JsQualifier or JsModule annotations)
  • [idl] Don't add import for the same package this file belongs to

see full CHANGELOG

Useful links

dukat's People

Contributors

maximilian-seitz avatar schahen avatar semoro avatar shabunc avatar trilis avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.