This is a migrated thread and some comments may be shown as answers.

Choosing between C#/XAML and JS/HTML for great UI performance

4 Answers 890 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ben Hoyt
Top achievements
Rank 1
Ben Hoyt asked on 18 Sep 2012, 04:04 AM
As developers new to Windows 8, we're having a hard time choosing between C#/XAML and JS/HTML for our upcoming app development. Telerik's RadControls for Metro are available for both platforms, and from our basic tests of Telerik's controls we can't tell much difference in performance.

We're developing a fairly photo-heavy application, kind of a photo viewer, so UI performance and responsiveness is key for us. That's pushing us towards C#/XAML, because our hunch is that it's going to perform significantly better than JS/HTML, which has to go through what's basically IE10's rendering engine, whereas C#/XAML should be a little bit closer to the metal. Is that assumption correct? Does anyone have any performance data or anecdotal evidence that C#/XAML would be the better route given our photo-heavy application?

Note that we don't have much experience with either set of technologies (esp on Windows 8, which is very new), so we can't exactly "use what we know".

4 Answers, 1 is accepted

Sort by
0
Ben Hoyt
Top achievements
Rank 1
answered on 18 Sep 2012, 10:20 PM
Oops, I'm sorry about the double post, I didn't see the first one appear for quite a while, so I tried again. I didn't see any way to delete one of them -- can this one be deleted?
0
James
Top achievements
Rank 1
answered on 29 Oct 2012, 11:38 AM
Not coding from Win 8 experience but from going through an in depth review of HTML5/JS performance vs native. I would throw in my 2 cents and say that XAML/C# will give you better performance. In starting to do my apps I did a very in depth analysis of what would perform better and while HTML5/JS is great in coding the same for all platforms when performing heavy data operations (we had a database application) native beat out H5/JS each time.
0
danparker276
Top achievements
Rank 2
answered on 30 Oct 2012, 07:47 PM
As for performace, isn't the HTML compiled for windows 8, so it wouldn't make a difference?  Or maybe the XAML is compiled better? (Just what I thought, I have no idea)

Also had a question for sharing files.  I currently XAML usercontrols between silverlight and WPF and telerik controls have no-problem.  When the same controls are available for windows 8, will I be able to share those same usercontrols?  

Also will telerik controls for HTML win8 be better or have more features than XAML win8?  

I'm thinking my WPF/Silverlight business apps are going to have a very different look and feel than anything I'd want on a tablet/phone.  I'd just share the web services.  Tablet/phone would be very similar and I'd probably share code between them.

I guess the advantage of HTML is that I could share it with my web pages.  I have a gut feeling that I wouldn't want to do that though.

If I prefer coding in XAML over HTML, I'm guessing I should always code Windows Phone 8 and Win 8 in XAML.

EDIT:
Just found 2 links on sharing code between phone and the windows store apps.  Seems like it is possible to share very basic usercontrols, but in most cases the XAML is going to be separate.
http://msdn.microsoft.com/en-US/library/windowsphone/develop/jj714088(v=vs.105).aspx
http://msdn.microsoft.com/library/windowsphone/develop/jj681693(v=vs.105).aspx

So is sharing better with HTML5?

0
Georgi
Telerik team
answered on 31 Oct 2012, 09:13 AM
Hi guys,

Thank you for sharing your opinions in  this interesting discussion.

Both technologies (C#/XAML & HTML) perform close regarding UI responsiveness and performance. There are some slight differences but from our experience, making components for each platform, we may say that the differences are insignificant. With that said, it is up to you and your skills to choose the platform that you feel more comfortable with. Otherwise we, at Telerik, will push hard to enrich both the XAML and the HTML parts of the suite so that we can offer our users same experience regardless of the platform.

Noticeable performance boost may be achieved if native C++/Direct2D rendering is used for some heavy UI scenes - e.g. rendering a Polyline primitive with thousands of points vs. using Direct2D. I have made a comparison demo and a blog about this:

Direct2D in XAML

But even in C++, the XAML rendering performs very close to the one in C#.

@Dan
As for the sharing between Win8 and SL/WPF - we are re-imagining every single control so that we can offer great user experience on touch devices as well as exceptional performance on low-end devices with limited hardware resources. Our goal is to offer APIs close to the ones found in our WPF/SL components but the internal implementation will be completely revamped.

I hope this information is useful. Do not hesitate to write us back with any feedback about our tools you may have.

Greetings,
Georgi
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
General Discussions
Asked by
Ben Hoyt
Top achievements
Rank 1
Answers by
Ben Hoyt
Top achievements
Rank 1
James
Top achievements
Rank 1
danparker276
Top achievements
Rank 2
Georgi
Telerik team
Share this question
or