Windows 8 MVVM Patterns Revealed

Author: Ashish Ghoda
Publisher: Apress
Pages: 148
ISBN: 978-1430249085
Audience: Existing C# programmers
Rating: 3.5
Reviewer: Ian Elliot

Windows 8 or specifically WinRT apps are ideal candidates for MVVM because, using XAML or HTML allows you to separate View from everything else very easily. This book offers to reveal the pattern for you. 

The subtitle is "Covers both C# and JavaScript" and the first four chapters are about C# with two final chapters discussing JavaScript.

Chapter 1 is an introduction to Windows Store app development using Visual Studio. There is a very short introduction to the View, ViewModel, Model class, but don't blink because you might miss it as it's just page and a half. The chapter also introduces the single example that runs through the entire book. In fact the best way to describe the book is to say that it is an explanation of this example and its development using the MVVM pattern. 




Chatper 2 explains the process of implementing the View and you will see a lot of XAML code. No drag-and-drop designer for this UI its all hand coded. It is all very detailed and it is difficult to see any general ideas. 

Chapter 3 moves on logically to developing the Model. No database was harmed in the making of this data retrieval system only the Windows local storage classes and serialization are used. 

Finally we reach the ViewModel in chapter 4. This introduces the idea of inversion of control using the Metroloc container from CodePlex. Be prepared for lots of C# code and more XAML. At the end I couldn't help think that coding such a simple app shouldn't be this complicated but the benefits of using a pattern like MVVM really only start to be felt when the application gets a bit bigger. With this example you can't but help notice the overhead involved in structuring things in this way. The book really doesn't go in for discussing the philosophy of the approach, so if you aren't already sold on the idea you might be left wondering why it's all so complicated. 

Chapter 5 moves us into the JavaScript HTML area of the book. It starts off with an overview of JavaScript development under Windows 8 and provides some basic details of programming in JavaScript. It reads like a conversion course for a C# programmer. If you are in need of such a conversion then this will be quite insufficient and leave you wondering what JavaScript is all about. The project used to illustrate the MVVM pattern is based on the use of the Knockout MVVM library. 





The final chapter is basically a reimplementation of the project developed earlier but in JavaScript and Knockout. It is basically a presentation of the code with explanations. The pace is much faster because is covers what takes three chapters in C#. Again there are a lot of long listings.

The JavaScript part of the book is more or less tagged on and really only serves to let the C# programmer see how it would be done in JavaScript. If your main interest is developing JavaScript apps this probably isn't going to help you unless you are prepared to read the C# chapters. 

If you are a C# programmer then it is a reasonable example of creating an app using XAML, but only if you are prepared to work through the example for real. This book doesn't have a lot of value if you plan to just read it, especially if you are going to just skim read the code. It is a detailed rather than overview sort of book and won't suit anyone who wants to have things mostly explained rather than just shown. 



C++ Programming, 6th Ed (In Easy Steps)

Author: Mike McGrath
Publisher: In Easy Steps
Date: April 2022
Pages: 192
ISBN: 978-1840789713
Print: 1840789719
Kindle: B09V2T9SJD
Audience: Developers wanting to learn C++
Reviewer: Mike James
This is the 6th edition of a slim book on C++. Can you really learn C++ in easy steps?

ChatGPT For Dummies

Author: Pam Baker
Publisher: For Dummies
Pages: 176
ISBN: 9781394204632
Print: 1394204639
Kindle: B0C63LZ6DN
Audience: Everyone
Rating: 4
Reviewer: Ian Stirk


This book aims to introduce you to ChatGPT, how does it fare?

More Reviews

Last Updated ( Wednesday, 20 November 2013 )