Uploaded image for project: 'Kogito'
  1. Kogito
  2. KOGITO-5824

TypeScript integration

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: Critical Critical
    • None
    • None
    • None
    • False
    • False

      We have come so far. A journey.

      We are able to perform the following:-

      • Generate "model" interfaces from an XSD
      • Generate concrete "model" classes from an XSD for a specific version of a model implementing the interfaces generated in the first step.
      • Generate concrete "marshallers" from the annotated "model" classes.
      • Compile this to run in JRE, GWT or J2CL environments.

      What we however miss is the ability to re-use this from within TypeScript itself.

      There are two competing approaches:-
      J2CL

      • Generate compiled JavaScript (with J2CL) from Java sources and re-use this from within a TypeScript development environment.
        > One problem is however that the Closure Compiler emits "goog" modules that are different to ES/AMD/UMD modules and hence need additional code generation to work with the current module support in TypeScript.
        > Another problem is also that we do not get TypeScript definitions generated (ts.d) making type-safe re-use of the library impossible. Additional code generation is needed.

      JSweet

      • Generate TypeScript source from Java source (with JSweet) and re-use the sources from within a TypeScript development environment.
        > One problem is however that JSweet does not handle dependencies (direct or transitive) out of the box automagically (like the J2CL Maven Plugin) and we'd need to repackage numerous dependencies as webjars to be re-usable by JSweet.

            kverlaen@redhat.com Kris Verlaenen
            manstis@redhat.com Michael Anstis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: