With the emerging of other Javascript runtimes (i....
# javascript
a
With the emerging of other Javascript runtimes (i.e. Deno & Bun), whats the future of running kotlin/js there?? Do we also use the
nodejs
target?? if so, won't the name be confusing?? Whats the plan of supporting this??
đź‘€ 4
g
I’m not really on topic about js runtimes, but I curious what exactly you mean? Isn’t all those runtimes just run Javascript code and Kotlin/JS transpiled to JS, same as Typescript I just don’t see what exactly Kotlin should support Using nodejs naming can be a bit confusing in this context I suppose, but after all you need some stdlib for server-side JS, even Bun as I see explicitly mentions node.js, because it implements node.js API (“natively implements hundreds of Node.js and Web APIs, including ~90% of Node-API functions”) So again, I do not have details, just curious about your question, what kind support you would like to see
a
While there is a huge overlap (Same way there is an overlap between nodejs and browser javascript), but there tiny subtleties (e.g. importing scripts directly from the web). So, the KGP does provide a way to target these different runtimes with there subtleties and even libraries that support those specific targets, so what are the plans for runing kotlin in those targets?? Are my questions clear??
g
But wouldn't kotlon/js just work as it is now, it's js after all, any additional APIs could be just added as a library I'm just not quite sure why special support is required, are you expecting to support bootstrapping those runtimes by Kotlin Gradle Plugin?
a
For you to understand my question, lets talk about the current KGP when targetting JS targets. How many targets does the KGP support when compiling to JS?? and more over, they are all targeting JS, right?? By why have different environments to run them on the KGP?
g
If I can compile Kotlin to JS I don't really worry about anything else I did it for server less applications long before any node.js was officially supported, it just js after all, everything else, like bootstrapping npm, yeaml are just whistles and bells imo I see now what you mean, it looks as a feature request for Gradle Plugin