Open vorburger opened 6 years ago
@pmlopes I hope that this is the right place to file this RFE idea?
I think the "next" step would be to follow the same approach https://github.com/reactiverse/es4x is using, by generating the proper JavaScript bindings and correct typescript definitions (which include enums)
That would allow the usage from both JS or TS and generation of proper documentation like this one for example: https://reactiverse.io/es4x/@vertx/core/index.html (where you can see both the types and docs extracted from the underlying interfaces).
E.g. here I've written for https://github.com/vorburger/minecraft-storeys-maker/issues/76 a
@ProxyGen
using Javaenum
(in that example both for an argument, see HandType; as well as for the return type, see ItemType) like this:and in the generated TypeScript signature (in
minecraft-storeys-maker/api/build/classes/java/main/Minecraft-ts/minecraft-proxy.ts
) this turned into:where, in an ideal world, it could be more "strongly typed" with a TypeScript enum :
@edewit FYI.