5 ms·
Working on a Silverlight app for my employer. I inherited this app from previous contractors and some of the stuff they did is pretty scary, so last night was t
by city41 16y ago
Working on a Silverlight app for my employer. I inherited this app from previous contractors and some of the stuff they did is pretty scary, so last night was the tipping point and I've decided to start ripping out all the bad stuff.
I'm also torn on Silverlight in general and seriously considering rewriting the app from scratch in an HTML framework (debating between Rails and ASP.NET MVC, even if that debate may seem like a silly one to some :) )
- amackera 16y agoIf you have the flexibility to rewrite the project in Rails, absolutely do it :)
- city41 16y agoI totally have the flexibility in that if I showed up with a Rails version of the app my boss would be all for it. But I don't have the flexibility to do it on company time. I am currently studying Rails 3 and getting a feel for how long I think it'd take to do this. I think a clean, well written Rails version of the app would make my life so much easier in the long run. Silverlight is an interesting beast. All in all I am finding it feels like writing a webapp in C# and a very strange "version" of HTML :) Especially when you use the Navigation Framework, the app becomes so website like it's ridiculous. I hate to think Microsoft wasted all that money, but I'm having a hard time coming up with Silverlight's strengths. Especially considering we are having issues with the Mac plugin, the promise of "write once" seems to not be met either. Granted it's two plugins versus half a dozen browsers (we don't support Moonlight at all), but still, if I'm going to be fighting how different platforms render my app, I might as well take advantage of the most ubiquitous and open platform there is. I can admit XAML was well conceived for layout flexibility and visual effects. But at the end of the day, that benefit is so small it's hardly worth considering.
- delano 16y ago... if I showed up with a Rails version of the app my boss would be all for it. But I don't have the flexibility to do it on company time. That's a long and tiring road.
- felideon 16y agoWhat's wrong with Silverlight? Just curious about your experience. I'm doing ASP.NET web forms at work and would much rather use Silverlight for a few things.
- city41 16y agoThere's not that much "wrong" with Silverlight. But I honestly can't find much "right" with it either. It just feels like Microsoft forked off and created this new platform that at the end of the day doesn't offer much benefit over HTML/JS/CSS. Granted, MS started Silverlight well before HTML5 started coming into form. Absolutely, C# is far more pleasant than JS and XAML is a nice alternative to HTML+CSS. All in all XAML was well thought out IMO. And since I'm knee deep in Silverlight right now, it's easy to forget how frustrating HTML/CSS/JS can be across all browsers. It's also easy to forget how difficult it is to test JavaScript code. My problems with Silverlight are: -- I really don't think it's going to become a dominate player, making my investment in Silverlight skills not nearly as effective as if I had taken this time to continue brushing up on my webapp abilities. -- It has its own CLR, making a lot of the .NET tool stack incompatible. There is still not an ideal way to test Silverlight components and especially no ideal way to integrate tests into your build tools. Silverlight is waaaaaaay behind here. There is a lot of people out there trying to solve this problem, but so far all the solutions (I've tried most of them) have serious drawbacks. Jeff Wilcox's Silverlight test framework is the best one so far, but it's very slow, cumbersome and buggy. -- Silverlight is incompatible with mobile devices. I have no hope of ever making this app work on the iPhone, Android or Blackberries. I suppose there is hope it will work on a Windows 7 Phone, but that's not enough. My Boss doesn't think this will ever matter to us, I'm not so sure. If we ever do decide we want a mobile version of our app, then at least the frontend of it will have to be completely rewritten from scratch. -- Absolutely everything in Silverlight is asynchronous. This isn't a real problem, per se, and is a good boon sometimes, but there are times when it's a pain in the butt. -- We have found the Mac Silverlight plugin and the PC Silverlight plugins have significant differences. Currently our app has serious flicker issues when ran on a Mac. We're not doing anything hacky, home brew, anything like that. The stuff that looks bad on the Mac is pure Silverlight code the way Silverlight was intended to work. I simply think the Mac plugin has more bugs and is a lower priority. I have no idea where Moonlight stands, but I have a feeling similar issues would occur. If I have to fight to get my app to run across all Silverlight plugins adequately, then IMO a major selling point of Silverlight is gone and I might as well just use HTML and fight to get it to to work across all browsers. At least dealing with browser issues is a common problem with a lot of solutions out there (a framework like Rails will even hide a lot of it). Dealing with Silverlight plugin issues? My only resource is the Silverlight forums and Microsoft Connect. I'm not nearly as hopeful there. -- We are forced to use the Microsoft stack. Yes you can host a XAP file in Apache on Linux, no problem. But if your Silverlight app needs to work with data, there's a very good chance you are going to choose WCF RIA Services (which we did). Bam, use IIS to host the app now or take the gamble with Mono. Not a gamble I want to take. I much prefer Apache over IIS. -- And ultimately, my real problem is as I write this app I just don't see any huge compelling features of Silverlight that makes all this worth it. Just about anything Silverlight can do, an equivalent modern webapp can do as well. Yes Silverlight does allow you to do this from the comforts of Visual Studio, C#, Blend and XAML. Much nicer waters to swim in than JS, without a doubt. But I just don't think I care. I think I'd rather deal with the current state of HTML/JS/CSS and end up with an app that potentially could be used on any device (within reason), can be hosted in Apache running on Linux, and can be a far lighter experience for the end user to boot.