torsdag 23 augusti 2012

Libraries and components

Since I didn't know very much about phone development when starting on DiceFeud, I tried out quite a lot of open source components, both for smaller details and for infrastructure. Some of them were tossed out but other ones were kept has proven to be very good and has really helped me figure out how things are done right.
If you are a Windows Phone developer and haven't checked this stuff out, you should. If you know of a good framework or component which I don't, please tell me about it.
Here is what I used:


I can't even begin to say how impressed I am with this project. ServiceStack is a web services framework which does everything right where WCF and other frameworks fail. It is developed and maintained by Demis Bellot, and a community of contributors are pitching in.
Whenever I have run into what I think may be a problem, ServiceStack has an elegant solution already in place.
In short, you publish a service in a most convenient fashion by writing a request- and a response class and boom! - you get endpoints for all kinds of client-server communication. Json, XML, Soap, REST and more, without any configuration hassle what so ever.
There is a whole lot more components in ServiceStack, but DiceFeud only uses the service-goodies and part of the authentication framwork. I can't see why I should ever use WCF again.


As much as I wanted to use ServiceStack on the client as well as the server, I ended up using RESTSharp on the client for serializing/deserializing JSON messages and sending requests to the server. ServiceStack didn't have a library suitable for WP7 when I began all this, and I figured it would take me too much time to make it work on my own. RESTSharp seems to do the job though.

MVVM Light

MVVM Light is a toolkit (not a framework) which essentially helps separating you UI from your businesslogic. It is written by Laurent Bugnion and he seems to have a pragmatic approach to application development which I find very compelling. DiceFeud is not a slave under MVVM - sometimes I had to cut corners in the codebehind files to make a detail work - but a lot of problems are solved for you by using this toolkit.

Windows Phone Assets

This package contains a few controls which are very useful. I used the Notification Tool to present message boxes in a very convenient way. The only problem with this control was that it didn't consider light/dark themes out of the box. Your app will fail certification if it doesn't look ok in both, so I had to tweak it a bit.


This package contains an application bar which works very well with MVVM. The standard application bar doesn't because it doesn't support commands in a convenient way.

Chat text block

This is a balloon message control used on the chat view in DiceFeud to get Metro looking messaing. (yes, Metro. Shame that name went down the drain)


This is a very sweet community package which contains page transitions and other stuff to make the app look a little more alive.

It really is a treat to see all the efforts of people sharing their work in libraries like these. Thank you so much. I wouldn't even want to think about the amount of time it would have taken me without them.

Inga kommentarer:

Skicka en kommentar