Windows 8 Metro / HTML5 JS “First Blood” Peter Kellner Microsoft MVP, ASP.NET ASPInsider Primary Organizer Silicon Valley Code.

Slides:



Advertisements
Similar presentations
JavaScript and AJAX Jonathan Foss University of Warwick
Advertisements

UNIT-e futures and UNIT-e Mobile Ben Potter Systems Architect.
Introduction to the Windows Runtime (WinRT) Ben Dewey Tallan, Inc.
Javascript Introduction Norman White Material is from w3schools.com Go there to run examples interactively.
Developing HTML5 Application using MVVM pattern Pekka Ylenius.
SharePoint Saturday Sponsors Gold Bronze Custom REST services and jQuery AJAX Building your own custom REST services and consuming them with jQuery AJAX.
Chapter 11 ASP.NET JavaScript, Third Edition. 2 Objectives Learn about client/server architecture Study server-side scripting Create ASP.NET applications.
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. M I C R O S O F T ® Preparing for Electronic Distribution Lesson 14.
Server- Side technologies Client-side vs. Server-side scripts PHP basic ASP.NET basic ColdFusion.
JavaScript & jQuery the missing manual Chapter 11
CS378 - Mobile Computing Web - WebView and Web Services.
Dynamic Web Pages (Flash, JavaScript)
AJAX in ASP.NET James Crowley Developer Fusion
Building Metro style apps with HTML and JavaScript Paul Gusmorino Lead Program Manager Microsoft Corporation.
Windows Store apps with HTML + Facebook integration
Angelo Chan Kamran Bilgrami. Agenda ● WinJS - What and Why ● Modern Apps ● WinRT Architecture ● Demos o Controls o Data Bindings o Program LifeCycle Management.
JQuery 10/21. Today jQuery Some cool tools around the web JavaScript Libraries Drawing libraries HTML Frameworks Conventions.
PowerPoint 1 The Basics 1. Save this file to your Apps Folder as YourLastName_PP1 2. Read each slide. 3. Complete each set of numbered directions.
Building Metro style apps with HTML and JavaScript Paul Gusmorino Lead Program Manager Microsoft Corporation.
WEB 304 An Overview of ASP.NET and Windows Workflow Foundation Kashif Alam Program Manager Developer Division Microsoft Corporation.
How to make a game using what you already know Chris Gardner Senior Software Engineer T & W Operations, Inc.
Understanding AJAX Hype, Hope, Hurt and Help for the Web MJTS May 4th, 2006 _________________________ Terence Conklin, Conklin Systems
JavaScript Patterns and Node Idioms by Rob Richardson
Cross Site Integration “mashups” cross site scripting.
Sponsors Gold Silver Bronze Custom REST services and jQuery AJAX Building your own custom REST services and consuming them with jQuery AJAX.
Ultra-modern web development (for.NET
Joe Hummel, PhD Microsoft MVP Visual C++ Technical Staff: Pluralsight, LLC Professor: U. of Illinois, Chicago stuff:
1 After completing this lesson, you will be able to: Transfer your files to the Internet. Choose a method for posting your Web pages. Use Microsoft’s My.
Sponsors Gold Silver Bronze Custom REST services and jQuery AJAX Building your own custom REST services and consuming them with jQuery AJAX.
Client-side processing in JavaScript.... JavaScript history Motivations –lack of “dynamic content” on web pages animations etc user-customised displays.
JavaScript Best Practices Learn How to Write Better Quality JavaScript Software University Technical Trainers SoftUni Team.
JavaScript Syntax, how to use it in a HTML document
RUBRIC IP1 Ruben Botero Web Design III. The different approaches to accessing data in a database through client-side scripting languages. – On the client.
Getting Started with ASP.NET MVC BRIJ BHUSHAN MISHRA.
Introduction to Windows 10 Windsor Senior Computer Users Group October 12, 2015.
Putting Performance Best Practices Together to Create the Perfect SPA Chris Love2Dev.com.
Building Excellent Internet & Intranet Solutions Dave Remmer Architect Advisor Microsoft Canada
Ajax for Dynamic Web Development Gregory McChesney.
WorldWide Telescope WWT HTML5 SDK WEB CONTROL WEB CLIENT DEVELOPMENT OVERVIEW RON GILCHRIST (WEB ON GITHUB NOV 7, 2015.
Web Components with Polymer Jeff Tapper Digital
Functions.  Assignment #2 is now due on Wednesday, Nov 25 th  (No Quiz)  Go over the midterm  Backtrack and re-cover the question about tracing the.
“The world’s most misunderstood language has become the world’s most popular programming language” Akshay Arora
Rich Internet Applications 2. Core JavaScript. The importance of JavaScript Many choices open to the developer for server-side Can choose server technology.
IS2803 Developing Multimedia Applications for Business (Part 2) Lecture 2: Introduction to IS2803 Rob Gleasure
UNDERSTANDING YOUR OPTIONS FOR CLIENT-SIDE DEVELOPMENT IN OFFICE 365 Mark Rackley
Bundles, Minification Andres Käver, IT Kolledž
Developing Windows 8 Style Application With HTML and JavaScript Lino Tadros | Falafel Software.
//liveVirtualacademy2011/ What’s New for ASP.NET 4.5 and Web Development in Visual Studio 11 Developer Preview Γιώργος Καπνιάς MVP, MCT, MCDP, MCDBA, MCTS,
Hartelijk welkom VB Event 26 september 2012 ‘Visual Studio 2012 voor de VB.NETWEB developer’ Alex Thissen – Achmea.
Office 365 Development July 2014.
JQuery Fundamentals Introduction Tutorial Videos
Introduction to.
Developing Windows 8 Style Application With HTML and JavaScript
JavaScript: Good Practices
What's new in the world of SharePoint development and deployment
Office 365 Development July 2014.
Mobile Navigation Control for Planetary Web Portals Team Members: John Calilung, Miguel Martinez, Frank Navarrete, Kevin Parton, Max Ru, Catherine Suh.
Tutorial 6 Topic: jQuery and jQuery Mobile Li Xu
AJAX.
Developing Branding Solutions for 2013
SharePoint-Hosted Apps and JavaScript
04 | Web Applications Gerry O’Brien | Technical Content Development Manager Paul Pardi | Senior Content Publishing Manager.
Creating Windows Store Apps Using Visual Basic
Dynamic Web Pages Jin Wu INF 385E Information Architecture
Build /2/2018 © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered trademarks.
Building responsive apps and sites with HTML5 web workers
SEEM4570 Tutorial 5: jQuery + jQuery Mobile
04 | Apps and SharePoint Chris Johnson | SharePoint Guru
Lecture 14: JSON and Web SERVICES
Blazor A new framework for browser-based .NET apps Ryan Nowak
Presentation transcript:

Windows 8 Metro / HTML5 JS “First Blood” Peter Kellner Microsoft MVP, ASP.NET ASPInsider Primary Organizer Silicon Valley Code Camp October 6 th and 7 th 2012

The Plan Intro To Windows 8 And Interface JavaScript Patterns In Windows 8 WinRT Basics Silicon Valley Code Camp Speaker Viewer

IE10Discusson Cut The Rope (runs Metro and Broswer) IE10 Browser IE10 Metro Strict mode required for Metro

The New UI The Lost Start Button (Win Logo Key) Charms (Search and Settings) (from left) The app bar (from top or bottom) Keyboard shortcuts Mouse Shortcuts Tablet Not Necessary

JavaScript Patterns For Windows 8 Fundamentals of JavaScript Libraries Tools Best Practices

Variable Scope JavaScript has: – Global scope (if forget var keyword) – Function scope – Defaults to global (Greedy) Metro style apps use single script context for the app – Doesn’t do page navigation – scopes don’t reset – Each “page” will need different scripts – Global scope can get really busy

Module Patten Defines annoymous function, execute immediately. Variables pulled into function scope. Still access global scope (WinJS.Navigation…) (function() { var x = 100; function attachListenersToStuffForExample() { zz = 10; } WinJS.Navigation.navigate(“/html/myapp1.html”); })();

Using Objects as Namespaces Helper in base.js WinJS.Namespace.define Example Usage: WinJS.Namespace.define(“MyNameSpace”,{ myUsefulFunction: function() { alert(‘hi’); } }); MyNameSpace.myUsefulFunction();

Defining Objects with WinJS Always put objects on Prototype (use WinJS helper methods, big perf increase) Example: var myObj = WinJS.Class.define( function() { }, { method1: function() {alert(‘hi’);} });

JavaScript Libraries Microsoft says: “JQuery Just works!” You can use other libraries! (test it yourself though) Exceptions: XHR differences, Host Enforcements, etc. (IE10 does not support cores, single domain not enforced, cores request fails)

Security Issues Host Enforcements Prevents “bad” HTML from getting inserted (script blocks,iframes,event handler,etc.) Reason is because JavaScript has full WinRT Parses innerHTML; outerHTML; setAdjacentHTML (data- are not on whitelist)

Contexts (you choose) Local Context (My Appointments) Full access to WinRT (all your code) Web Context (bing app with map) Full access to Web Pull Scripts No Calls to WinRT (window.PostMessage To Send Data Between (need to marshal data because string))

WinJS Basics Helpers for NS/Constructor Definitions Promises Nav/App Model Page Fragments Data Binding Controls Animations And More

App Model Page Loads Scripts Loads Script Executes Hookup to Events Page Shows

Promises / Async Processing Object that says: “I want you to do something and tell me later” Hence “Then” with 3 callback functions. (success,failure,error) Very similar to other frameworks WinJS.xhr({url: “

In-box controls for Metro style apps

DataBinding Engine Oneway only (Data to UI) Async (coalescing, just one change)

The SV Code Camp App Off to the Demo…

References BUILD Videos Windows Libraries for JavaScript (WinJS) Building Metro Style Apps With JavaScript

Questions Peter Kellner Mobile Web Developer / Server Side & Client Side Consultant/Architect (looking for clients!) MVP, ASP.NET Development including publishing 4 MSDN Articles on ASP.NET 2.0 Organized Silicon Valley Code Camps Complete Custom Insurance Co. Management s/w to run $200M business – 2001 President Tufden Inc. Built and Delivered: 500 doctor office turnkey computer systems; University Clinic Scheduling System;. Cornell University BS,MS Engineering