Download - 2012 mct summit presentation final
![Page 1: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/1.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
Deep Dive into WinJS
Dmitri Artamonov
@dartamon
![Page 2: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/2.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Your name• Web, client or other?• What’s drawing you towards WinJS?
Introductions
![Page 3: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/3.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Introductions• Under the hood• Place in the universe• Patterns and practices• Integration with enterprise systems• Managing WinJS development
Agenda
![Page 4: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/4.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 5: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/5.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Language projections• Connected to same WinRT components• Hardware-accelerated JS technology from IE• Will WinJS evolve away?• Windows Phone 8
Under the hood
![Page 6: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/6.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 7: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/7.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Rapid Development• Reuse web monkeys• Better view surface on top of C# logic• Large existing ecosystem for developers• Cheaper UI design process
Where does it fit?
![Page 8: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/8.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 9: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/9.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• jQuery• Graphing and Charting• Knockout.js• You can even create apps without WinJS
Other Libraries
![Page 10: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/10.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Async pattern• function – then – done• Still a single thread!• Careful accessing resources not yet returned
Patterns - Promises
![Page 11: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/11.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• No encapsulation of actions• Bloated VMs• Implementation – one context per view• No two-way bindings in WinJS• Bindings in WinJS require knowledge of View
Patterns – MVVM…
![Page 12: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/12.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 13: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/13.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 14: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/14.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 15: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/15.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Standard web pattern for ~17 years• Controllers for user input• AM/DM conversion with namespaces and
classes• Classes and namespaces are observable• Multiple contexts – regions…
Patterns - MVC
![Page 16: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/16.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
Demo - MVC
![Page 17: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/17.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Data contexts defined for individual DOM elements
• data-win-bind and data-win-bindsource• Declarative and programmatic ways
Patterns - Regions
![Page 18: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/18.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Information hiding done via modules• Anonymous self-executing function with
parameters• Code inside module is private• Parameters allow dependency injection and
testing• Data exposed via namespaces and classes
Patterns – Modules and DI
![Page 19: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/19.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• C# good at logic and model manipulation• Use it, expose data via component to WinJS• Access it as normal namespace/class• Take advantage of performance of C++/C#
Patterns – .winmd components
![Page 20: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/20.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Deploy once, keep updating• Forbidden by security for the Windows Store• Uses execUnsafeLocalFunction• Alternatives – iframe, Fragments API
Patterns - Dynamic code loading
![Page 21: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/21.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Blend with WinJS• No broken module references or .targets files• True handoff from designer to developer
Practices – Blend design process
![Page 22: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/22.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
Demo – Blend with Javascript
![Page 23: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/23.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• File Picker API - fluid file system• Roaming API – unified experience• Share Contract – enterprise workflows• Tiles – enterprise dashboards• Windows Push Notification Services for
communication through tile updates
Integration with Enterprise Systems
![Page 24: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/24.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
Demo – Executive Dashboard
![Page 25: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/25.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Private store for the enterprise• Enterprise machines can deploy from fixed set
of apps• Enforce security policies• Restores controlled enterprise environment
Enterprise Store (unofficial)
![Page 26: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/26.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
![Page 27: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/27.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• Training• Design – Blend!• Development• Testing• Deployment• Maintenance
Managing WinJS - Costs
![Page 28: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/28.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• What happens to legacy C# apps?• How to migrate legacy web applications to
Windows 8?• Writing cross-platform apps
Managing WinJS (cont’d)
![Page 29: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/29.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
A Big Thanks to our Sponsors
Platinum Sponsor
Gold Sponsors
![Page 30: 2012 mct summit presentation final](https://reader034.vdocuments.us/reader034/viewer/2022052618/54b3b6544a7959a8438b45b5/html5/thumbnails/30.jpg)
MCT Summit North America | October, 17th – October 20th, 2012 | Redmond
• WinJS Samples: http://code.msdn.microsoft.com/windowsapps/Windows-8-Modern-Style-App-Samples
• BlueMetal Blog: http://blog.bluemetal.com• [email protected]• @dartamon
Questions?