What tools generate JavaScript?

Are there any good tools for generating JavaScript? I remember that in .NET there was Script # - I don’t know my status today.

Does anyone have any experience with any tools?

+4
source share
9 answers

I use my keyboard, text editor and my brain to generate JavaScript.

: R

+3
source

As others have said, GWT is a very good option. To summarize:

  • fast, very portable code using delayed binding; it only downloads code that runs in the user's browser, and only loads functions that are actually called; also, they are compressed
  • reliability ; very few known problems.
  • simplified debugging using the Java IDE; you can also look at un-obfuscated javascript if you want, but it seems (based on some reports that I saw and personal experience) that you basically never need this.
  • support for a good library , including a beautiful built-in javascript interface, the ability to use existing Java libraries, and special support for ajax / rpc calls
  • extensible and stylistically flexible ; you can customize all styles with your own css rules and extend your Widget base with your own Java subclasses.

So, I humbly disagree with the dominance that the results are ugly, as the encoder should “muffle” the basic functionality with its own CSS rules and other decorations. It would be the same mistake to call HTML “ugly” - if you do not try hard, it is ugly, but the strength and flexibility are in the hands of the encoder.

Oh, and this is also open source.

+2
source

The latest version of Script # was posted less than a month ago. Nikhil continues to actively work on this project, and it is a very good tool for generating JavaScript code from C #. It is actively used in several different internal Microsoft projects.

Some of the benefits of Script #:

  • Intellisense
  • Compilation error at compile time
  • Refactoring Support
  • Documentation Support
  • FxCop Code Analysis
  • MSBuild Support
+1
source

There are currently many tools for generating JavaScript, such as GWT.

But giving you a good answer really depends on what your initiator language is and what kind of JavaScript functionality king you want to use.

0
source

The Google Web Toolkit is one option. Write Java code, debug it with a standard Java debugger, then click the Compile button and turn it into highly optimized JavaScript. It generates a completely separate JavaScript for each major family of browsers (IE, Firefox, Safari, etc.).

Very mature, very powerful and easy to embed in an existing site. One drawback is that the user interfaces it creates are ugly nested tables.

0
source

I used D-templates (I think C ++ is pain-free and you will be 50% there) to create an AJAX-based proxy object.

0
source

Try Haxe .

It can target JavaScript, ActionScript, and Neko bytecode. The language is close to Java.

0
source

Kotlin can generate JavaScript from Kotlin code. For Kotlin, see http://kotlin.jetbrains.org/ , as well as http://devnet.jetbrains.com/thread/447468?tstart=0

0
source

Source: https://habr.com/ru/post/1276792/


All Articles