GWT vs ScriptSharp Pros and Cons

We have determined that it is too difficult for us to support the main part of javascript that we need to write full-blown “one-page” javascript applications. Relying on programming conventions, we still didn't want to ... especially in the field of refactoring. For developers new to these projects, it is very difficult for them to change anything because they do not believe that they know who else really relies on the component (which is easy to do with "find all links ..." and the levels of access to the code are very typed languages).

We played with GWT, but one of our developers wants to use Script #. We are already a Microsoft-based store and do all our server work in C #.

I do not consider java as a show-stopper for GWT, since it is very similar to C #.

My initial problems with Script # primarily concerned support and documentation.

On the one hand we have Google, on the other ... "Some Dude". Script # is also a closed-source ... so if a developer stops working on it, will we be SOL? I also feel that GWT has more documentation and community support.

In any case, have you worked with both? Thoughts? Pros / Cons?

(To head this on the pass: the question is not whether to go with the compiler or not ... the question is which compiler)

Similar but different questions:

What benefits can ScriptSharp bring to my toolbox?
Should I use ScriptSharp

+4
source share
4 answers

I have been using GWT for several years. I have never heard of Script #, so I’ll just tell you why you should stick with Google's solution.

  • Active development. Google has a paid team of engineers who are actively correcting flaws and working on new functionality. I am currently discussing with some other developers how to implement a new feature for GWT.

  • Large institution. Google invested in this project and used it to implement large-scale solutions. In other words, they eat their own dog. They are interested in not letting it stagnate or become obsolete.

  • Community There are many people who work on add-ons / third-party / other libraries and APIs to use along with vanilla distribution. These same people also test, register and fix defects.

  • Compatibility. GWT can work with everything the browser can do. There are also plugins for jQuery and other major JavaScript libraries that make it easy to manage the complexity of your project when working with JavaScript.

  • Open You touched it yourself.

Please note that I did not deal with language selection issues. I do not think that this is really relevant at the level that you are describing. Remember that the first time you encounter a restriction or road block with Script #, you get stuck quickly because we described you too.

Of course, I recommend GWT only because of the track recording.

+8
source

I am using Script # and have previously used GWT. They are really two different things. GWT is designed to provide a client and server solution with RPC and everything else. It is definitely more mature and you can switch to complex applications faster. Simply put, in the wild there is much more code and examples.

However, I think that if you are developers on both the server side and the client side, using two different languages ​​and two different platforms can be very, very burdensome. This is why I moved to Script #. All I do is in C # and in Visual Studio, this allows me to be more productive. If you are not taking advantage of the GWT backend, this is really overkill.

I like to think of Script # as Javascript written in the C # 2.0 specification (which is). This is a fully client-side interface, and any mapping must be done manually (although automatic use can be widely used). This is very complete in support of Javascript and jQuery, in fact it is so complete that it surprised me at first. He seemed to be doing less than it was.

HenriDale's points are valid, especially with regard to community and openness. Although it was a bit of a thorn on my side, I really enjoy using Script #. I do not need to change the IDE, I do not need to look for how to do something in Java, etc. JQuery has a huge library of plugins, and it’s very easy to connect them to Script #. You simply drop a few objects to represent the properties, annotate them as "imported", and return null. In your code, you throw the object as a plugin, and your result is exactly the same as in Javascript. Script # does not care / does not know how the plugin works.

Do not let Script # a lack of community support fool you. Although this is a problem, the product is very mature and multifunctional. If your developers use C # / VS, why would they use a separate client program? I found that it was a huge success.

As an aside, I have become much better in Javascript since I used C #. Many problems with Javascript are the lack of language features that you really don't need, but in large projects this is the only way to make it manageable.

+14
source

If you want to use C # for your JavaScript code, I would suggest SharpKit . It has a comparison of features with other C # solutions. Also, as an example of his application, you can check out CodeRun , which is created using SharpKit.

+4
source

If you do not create a fully functional application in the browser, I prefer Script # because it adheres to what it does best - compiling C # in JavaScript - rather than trying to be a full client / server Toolkit. Web paradigms are changing rapidly, and investing in a GWT project can leave you with overhead or technology obligations that you did not want. But I would add that it really depends on the type of web application or web experience you are trying to create.

Personally, I am already familiar with jQuery, WCF, and I'm starting to use the new HTML5 features directly. Script # is the perfect missing piece because I can use jQuery and WCF very easily, and I don’t need to iterate over switching or integration with GWT paradigms or requirements.

Also, on the UI side, you might think of the Sharp UI that I recently discovered, which makes it easy to build reusable controls in jQuery + Script # setup.

+3
source

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


All Articles