But what I really want is a way to convert Silverlight to JS. I don't care whether it is source or binary level conversion, but it would be awesome to take projects we've written in silverlight and run them on any browser without a plugin.
New C# to Javascript compiler released
61–70 of 81 posts
Re: New C# to Javascript compiler released
#62Earlier quoted context omitted.
Yes no limits to abstractions always works perfectly.. Check out this stack trace: http://www.ibm.com/developerworks/java/library/os-ecspy1/sta... Now imagine that across three different languages.
Java has been said to be a DSL to convert XML configuration into stack traces. But what does this have to do with compiling C# to Javascript?
Re: New C# to Javascript compiler released
#63Having the ability to run the same code in the browser and on the server, in C#, is really a big thing for me.
I think the debugging problem stated in many comments here is overrated: If you're writing an app the size that seriously benefits from the modularity, the tool support and the type checking of a language like C#, you will have a relatively small amount of code directly touching the DOM. All of that other code can be simply unit tested in C#-o-world, straight from the dev environment. If you're writing C#, don't test and debug like it's JS!
Surely such an approach won't catch all bugs and the occasional leaky abstraction (or compiler bug), but it should get one pretty far. Some in-browser unit testing lib together with the fact that the generated JS is quite readable indeed, should help me get the rest of the way.
Can't wait to dive in!
Re: New C# to Javascript compiler released
#64Not entirely the same, but for those of us on Window, I prefer the look of http://jsil.org .
JSIL is also great, but its philosophy is that yo write .net code and run it in the browser, whereas Saltarelle's (and Script#'s) is that you write Javascript but with better tools. Also, the script that JSIL generates is very far from what you would write by hand, whereas that generated by Saltarelle/Script# can be distinguished from hand-written script primarily because the indentation is always correct and there i…
Another question, did you do any performance comparisons of Saltarelle? (to normal C# builds, to JSIL, or anything else?)
Re: New C# to Javascript compiler released
#65How does this compare to http://sharpkit.net (free for small and open source projects) Feature wise? SharpKit seems more complete (language support and has source map debugging support on Chrome). Also support for all popular JS libraries.
SharpKit is only free as long as you want to use it for projects that don't need it (the limit is like 2k lines or something). When I last tried it I was not very happy with the code it generated. Additionally, it uses the standard mscorlib so it is not unlikely that you will end up calling methods that are not implemented (which is the very problem the tool is designed to avoid). If it were open source, I would have…
Re: New C# to Javascript compiler released
#66Earlier quoted context omitted.
The reason I'm looking for either C# / Scala JS compiler is that I'm a static typing fan, I am an old school developer who likes IDEs and like discovering API by pressing ctrl+space, instead of mentally knowing it or constantly checking the API docs, I know it's against the trend, and not considered cool, but this gets me working software out the door. I'm much more productive and have much less bugs while writing ol…
I hear you, but I can't agree. Maybe it's my background. For 13 years as a professional developer my primary languages were Perl and Javascript, using Vim and the Unix command-line as my IDE. For the past 1.5 years I've swapped C# for Perl and Visual Studio for my IDE (still have a vi emulator though.) Intellisense is definitely useful, but I find it gets in the way a lot... both literally by overlapping the code aro…
What I'm wondering is, why can't we have the browser then be our IDE, chrome already supports editing, just need to persist it to my code base
By the way, I strongly suggest using something like resharper, VS is great, but I found eclipse much better if you are looking for those tricks and shortcuts.
If you haven't tried it yet, I encourage anyone to get eclipse, put in some java code, and play with ctrl+1 magic shortcut (mark anything in code and let it do the work for you) it allows you to be more expressive and write code in a modular way, for example, I don't have to be a boolean logic master, or even a smart developer to extract negation up a boolean condition, and if I forgot a param / method, it will create it for me with the right signature, and if I see a piece of string I want to replace with a variable, it takes it for me and adds those dreadful " + ... + " in so I don't have to. does it makes you a zombie programmer? probably yes, does it make you smarter? probably not, but does it make you more productive? absolutely yes.
again, VS I think is nowhere near eclipse JDT in that end (without resharper at least)
I think this is why GWT, Dart, Scala, Hibernate / Seam, Spring all invest so much in eclipse,
most developers of this world (me included) are just not good enough hackers to do it the VIM / grep way... sad but true.
Re: New C# to Javascript compiler released
#67Earlier quoted context omitted.
The reason I'm looking for either C# / Scala JS compiler is that I'm a static typing fan, I am an old school developer who likes IDEs and like discovering API by pressing ctrl+space, instead of mentally knowing it or constantly checking the API docs, I know it's against the trend, and not considered cool, but this gets me working software out the door. I'm much more productive and have much less bugs while writing ol…
I hear you, but I can't agree. Maybe it's my background. For 13 years as a professional developer my primary languages were Perl and Javascript, using Vim and the Unix command-line as my IDE. For the past 1.5 years I've swapped C# for Perl and Visual Studio for my IDE (still have a vi emulator though.) Intellisense is definitely useful, but I find it gets in the way a lot... both literally by overlapping the code aro…
I sometimes forget that this is the default, since my first step when installing VS.NET is to turn off all the automatic popping up and getting your way functionality. I think it's analogous to that "Torch Mode" setting that new TVs are on when they're in the showroom, demonstrating every feature they have at once so you see it all and are impressed. The VS.NET that I know doesn't do that. But I guess it would prefer to if you didn't reel it in.
Keep all the good stuff, but leave it behind CTRL+Space. You're four checkboxes away from having your cake and eating it too. And not having it leap up in between you and what you're trying to accomplish.
Re: New C# to Javascript compiler released
#68The very best of luck when it comes to debugging the code when it is running in the browser. Maybe your experiences are different to mine but I avoid such abstractions wherever possible. It has become fashionable to say things like "JavaScript ... is not well suited for developing large systems" - indeed so much so it often passes without comment but when it is JavaScript that will be run by the browser then JavaScri…
Re: New C# to Javascript compiler released
#69Earlier quoted context omitted.
I think what you're saying is a given...
The author might assume it, but I think it needs to be explicitly stated. Tools like this are often sold as "You don't need to know X because you can now code in Y and translate automatically to X!" That never works out though because there are always leaky abstractions. (For this project, just take a look at the Attributes docs to see how leaky the abstractions are.) I've had to work with a bunch of C, C++, Java, Pe…
Re: New C# to Javascript compiler released
#70Earlier quoted context omitted.
The reason I'm looking for either C# / Scala JS compiler is that I'm a static typing fan, I am an old school developer who likes IDEs and like discovering API by pressing ctrl+space, instead of mentally knowing it or constantly checking the API docs, I know it's against the trend, and not considered cool, but this gets me working software out the door. I'm much more productive and have much less bugs while writing ol…
I hear you, but I can't agree. Maybe it's my background. For 13 years as a professional developer my primary languages were Perl and Javascript, using Vim and the Unix command-line as my IDE. For the past 1.5 years I've swapped C# for Perl and Visual Studio for my IDE (still have a vi emulator though.) Intellisense is definitely useful, but I find it gets in the way a lot... both literally by overlapping the code aro…
https://developers.google.com/closure/
There are no editors that give you the nice intellisense bells and whistles, but static typing is by far the most important for me.