SlideShare uma empresa Scribd logo
1 de 10
Single Page Apps

HTML5, ASP.NET Web API, Knockout
         Fabrizio Iezzoni
        @fabrizioiezzoni
Thanks to the sponsors
What’s a SPA?
• A rich and responsive web app built with
  HTML5, CSS and JavaScript
• Fits in a single page (but is not a strict
  requirement) providing a “fluid” experience
  without full page loadings
• All necessary code is loaded once (bootstrap)
• Persists the state on the client
SPAs are Everywhere
• Gmail (and many other Google services like
  Analytics, Docs, etc)
• Windows Azure Management Portal
• Facebook and Twitter
• Hipmunk
• Trello
• CloudDocument
• Apple iCloud
SPA Architecture
                                Visible UI
    Web UI
                                HTML/CSS
  HTML/CSS/JS

  Data services
   JSON/XML                  Application layer   Navigation
                                JavaScript         APIs



                             Data access layer
                                JavaScript



                              Local storage
Server             Client
Frameworks and Libraries
• Building a SPA without the proper tools is hard
• Many frameworks and libraries emerged:
  – AngularJS, BackboneJS, BatmanJS, CanJS, Ember,
    KnockoutJS, Meteor, Spine
• All adopt some sort of MV* pattern
• Templating: DOM-based vs string-based
• Some components are integrated (or optional),
  other must be added using external libraries
  (for example model/data storage or routing)
Knockout.js
• Developed and mantained by Steve Anderson
  (formerly ASP.NET team member)
• Open Source project (NOT Microsoft)
• It’s part of the ASP.NET MVC 4 template
• Model-View-ViewModel (MVVM) pattern
• Commanding, Change Tracking, Templating
  and Validation
• All the rest must be integrated with other
  libraries
Demo app: SPAtube
• Very simple but complete SPA
• Youtube player with a simple database for
  storing private playlists and membership data
• Source code on GitHub:
      https://github.com/popapps/SPAtube

• Live app on AppHarbor:
      http://spatube.apphb.com/
SPAtube: ingredients
     DOM                  jQuery            others

       UI            Twitter Bootstrap   Underscore.js

 Data binding
   MVVM                Knockout.js          Toastr

   AJAX, data
 push/pull, client      Amplify.js        Moment.js
storage, pub/sub

 Nav / History          Sammy.js
 Dependency
  resolution
                        Require.js
Please rate this session
Scan the code, go online, rate this session

Mais conteúdo relacionado

Mais procurados

опыт использования схемы Drupal+varnish+nginx руслан исай
опыт использования схемы Drupal+varnish+nginx руслан исайопыт использования схемы Drupal+varnish+nginx руслан исай
опыт использования схемы Drupal+varnish+nginx руслан исай
drupalconf
 
Introduction To Single Page Application
Introduction To Single Page ApplicationIntroduction To Single Page Application
Introduction To Single Page Application
KMS Technology
 

Mais procurados (20)

The Dark Side of Single Page Applications
The Dark Side of Single Page ApplicationsThe Dark Side of Single Page Applications
The Dark Side of Single Page Applications
 
Tech Stack Ideas
Tech Stack IdeasTech Stack Ideas
Tech Stack Ideas
 
What is a good technology stack today?
What is a good technology stack today?What is a good technology stack today?
What is a good technology stack today?
 
A Gentle Introduction to Blazor
A Gentle Introduction to BlazorA Gentle Introduction to Blazor
A Gentle Introduction to Blazor
 
Testing your Single Page Application
Testing your Single Page ApplicationTesting your Single Page Application
Testing your Single Page Application
 
опыт использования схемы Drupal+varnish+nginx руслан исай
опыт использования схемы Drupal+varnish+nginx руслан исайопыт использования схемы Drupal+varnish+nginx руслан исай
опыт использования схемы Drupal+varnish+nginx руслан исай
 
Introduction to Vue.js DevStaff Meetup 13.02
Introduction to Vue.js  DevStaff Meetup 13.02Introduction to Vue.js  DevStaff Meetup 13.02
Introduction to Vue.js DevStaff Meetup 13.02
 
Platforms based on WordPress
Platforms based on WordPressPlatforms based on WordPress
Platforms based on WordPress
 
Introduction To Single Page Application
Introduction To Single Page ApplicationIntroduction To Single Page Application
Introduction To Single Page Application
 
Moving from PHP to a nodejs full stack CMS
Moving from PHP to a nodejs full stack CMSMoving from PHP to a nodejs full stack CMS
Moving from PHP to a nodejs full stack CMS
 
Introduction to Web Technology Stacks
Introduction to Web Technology StacksIntroduction to Web Technology Stacks
Introduction to Web Technology Stacks
 
Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012
 
Signal rity1
Signal rity1Signal rity1
Signal rity1
 
Node ts1
Node ts1Node ts1
Node ts1
 
WordPress as an Application Framework
WordPress as an Application FrameworkWordPress as an Application Framework
WordPress as an Application Framework
 
LatJUG. JSF2.0 - The JavaEE6 Standard
LatJUG. JSF2.0 - The JavaEE6 StandardLatJUG. JSF2.0 - The JavaEE6 Standard
LatJUG. JSF2.0 - The JavaEE6 Standard
 
Building enterprise applications on the cloud (Level 100)
Building enterprise applications on the cloud (Level 100)Building enterprise applications on the cloud (Level 100)
Building enterprise applications on the cloud (Level 100)
 
Basic method for Java EE Web Profile
Basic method for Java EE Web ProfileBasic method for Java EE Web Profile
Basic method for Java EE Web Profile
 
Em presentation victor herman
Em presentation victor hermanEm presentation victor herman
Em presentation victor herman
 
Building WordPress sites with AngularJS and the RESTful plugin JSON API
Building WordPress sites with AngularJS and the RESTful plugin JSON APIBuilding WordPress sites with AngularJS and the RESTful plugin JSON API
Building WordPress sites with AngularJS and the RESTful plugin JSON API
 

Destaque (7)

Orientamento pt pt
Orientamento pt ptOrientamento pt pt
Orientamento pt pt
 
Pei italia fr
Pei italia frPei italia fr
Pei italia fr
 
Orientamento pt fr
Orientamento pt frOrientamento pt fr
Orientamento pt fr
 
Pei italia fr
Pei italia frPei italia fr
Pei italia fr
 
Pdf E Pei
Pdf E PeiPdf E Pei
Pdf E Pei
 
Sostegno formazione mod 2
Sostegno formazione mod 2Sostegno formazione mod 2
Sostegno formazione mod 2
 
Pei italia fr
Pei italia frPei italia fr
Pei italia fr
 

Semelhante a WebNetConf 2012 - Single Page Apps

Benefits of an Open environment with Wakanda
Benefits of an Open environment with WakandaBenefits of an Open environment with Wakanda
Benefits of an Open environment with Wakanda
Alexandre Morgaut
 
Intro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NETIntro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NET
Alan Hecht
 
6 weeks 6 months live project summer industrial training in cmc limited 2012
6 weeks  6 months live project summer industrial training in cmc limited  20126 weeks  6 months live project summer industrial training in cmc limited  2012
6 weeks 6 months live project summer industrial training in cmc limited 2012
CMC Limited
 

Semelhante a WebNetConf 2012 - Single Page Apps (20)

ITT Flisol 2013
ITT Flisol 2013ITT Flisol 2013
ITT Flisol 2013
 
Benefits of an Open environment with Wakanda
Benefits of an Open environment with WakandaBenefits of an Open environment with Wakanda
Benefits of an Open environment with Wakanda
 
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and AngularEscaping the yellow bubble - rewriting Domino using MongoDb and Angular
Escaping the yellow bubble - rewriting Domino using MongoDb and Angular
 
Titanium: Native Mobile Apps with Javascript
Titanium: Native Mobile Apps with Javascript Titanium: Native Mobile Apps with Javascript
Titanium: Native Mobile Apps with Javascript
 
Modern Web Framework : Play framework
Modern Web Framework : Play frameworkModern Web Framework : Play framework
Modern Web Framework : Play framework
 
20120306 dublin js
20120306 dublin js20120306 dublin js
20120306 dublin js
 
JHipster
JHipsterJHipster
JHipster
 
Building Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript FrameworksBuilding Enterprise Grade Front-End Applications with JavaScript Frameworks
Building Enterprise Grade Front-End Applications with JavaScript Frameworks
 
Developing Cross-Platform Web Apps with ASP.NET Core1.0
Developing Cross-Platform Web Apps with ASP.NET Core1.0Developing Cross-Platform Web Apps with ASP.NET Core1.0
Developing Cross-Platform Web Apps with ASP.NET Core1.0
 
Angular jS Introduction by Google
Angular jS Introduction by GoogleAngular jS Introduction by Google
Angular jS Introduction by Google
 
Single page applications with backbone js
Single page applications with backbone jsSingle page applications with backbone js
Single page applications with backbone js
 
Lessons Learned from Real-World Deployments of Java EE 7 at JavaOne 2014
Lessons Learned from Real-World Deployments of Java EE 7 at JavaOne 2014Lessons Learned from Real-World Deployments of Java EE 7 at JavaOne 2014
Lessons Learned from Real-World Deployments of Java EE 7 at JavaOne 2014
 
Frameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic ReviewFrameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic Review
 
DIGIT Noe 2016 - Overview of front end development today
DIGIT Noe 2016 - Overview of front end development todayDIGIT Noe 2016 - Overview of front end development today
DIGIT Noe 2016 - Overview of front end development today
 
Intro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NETIntro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NET
 
Vincent biret azure functions and flow (ottawa)
Vincent biret azure functions and flow (ottawa)Vincent biret azure functions and flow (ottawa)
Vincent biret azure functions and flow (ottawa)
 
Vincent biret azure functions and flow (toronto)
Vincent biret azure functions and flow (toronto)Vincent biret azure functions and flow (toronto)
Vincent biret azure functions and flow (toronto)
 
Vlad Zelinschi - Embrace Native JavaScript (the anti-plugins talk) - Codecamp...
Vlad Zelinschi - Embrace Native JavaScript (the anti-plugins talk) - Codecamp...Vlad Zelinschi - Embrace Native JavaScript (the anti-plugins talk) - Codecamp...
Vlad Zelinschi - Embrace Native JavaScript (the anti-plugins talk) - Codecamp...
 
Build Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJSBuild Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJS
 
6 weeks 6 months live project summer industrial training in cmc limited 2012
6 weeks  6 months live project summer industrial training in cmc limited  20126 weeks  6 months live project summer industrial training in cmc limited  2012
6 weeks 6 months live project summer industrial training in cmc limited 2012
 

Mais de Pop Apps

Pei italia fr
Pei italia frPei italia fr
Pei italia fr
Pop Apps
 
Pei italia fr
Pei italia frPei italia fr
Pei italia fr
Pop Apps
 
Orientamento pt it
Orientamento pt itOrientamento pt it
Orientamento pt it
Pop Apps
 
Orientamento it fr
Orientamento it frOrientamento it fr
Orientamento it fr
Pop Apps
 
Orientamento it it
Orientamento it itOrientamento it it
Orientamento it it
Pop Apps
 
Orientation fr it
Orientation fr itOrientation fr it
Orientation fr it
Pop Apps
 
Orientation fr fr
Orientation  fr frOrientation  fr fr
Orientation fr fr
Pop Apps
 
valutazione portogallo fr
valutazione portogallo frvalutazione portogallo fr
valutazione portogallo fr
Pop Apps
 
valutazione portogallo it
valutazione portogallo itvalutazione portogallo it
valutazione portogallo it
Pop Apps
 
valutazione portogallo pt
valutazione portogallo ptvalutazione portogallo pt
valutazione portogallo pt
Pop Apps
 
Valutazione francia fr
Valutazione francia frValutazione francia fr
Valutazione francia fr
Pop Apps
 
Valutazione italia it
Valutazione italia itValutazione italia it
Valutazione italia it
Pop Apps
 
Valutazione francia it
Valutazione francia itValutazione francia it
Valutazione francia it
Pop Apps
 
Valutazione italia fr
Valutazione italia frValutazione italia fr
Valutazione italia fr
Pop Apps
 
Pei portogallo pt
Pei portogallo ptPei portogallo pt
Pei portogallo pt
Pop Apps
 
Pei portogallo it
Pei portogallo itPei portogallo it
Pei portogallo it
Pop Apps
 
Pei portogallo fr
Pei portogallo frPei portogallo fr
Pei portogallo fr
Pop Apps
 
Pei portogallo (pt)
Pei portogallo (pt)Pei portogallo (pt)
Pei portogallo (pt)
Pop Apps
 
Pei portogallo (it)
Pei portogallo (it)Pei portogallo (it)
Pei portogallo (it)
Pop Apps
 
Pei portogallo (fr)
Pei portogallo (fr)Pei portogallo (fr)
Pei portogallo (fr)
Pop Apps
 

Mais de Pop Apps (20)

Pei italia fr
Pei italia frPei italia fr
Pei italia fr
 
Pei italia fr
Pei italia frPei italia fr
Pei italia fr
 
Orientamento pt it
Orientamento pt itOrientamento pt it
Orientamento pt it
 
Orientamento it fr
Orientamento it frOrientamento it fr
Orientamento it fr
 
Orientamento it it
Orientamento it itOrientamento it it
Orientamento it it
 
Orientation fr it
Orientation fr itOrientation fr it
Orientation fr it
 
Orientation fr fr
Orientation  fr frOrientation  fr fr
Orientation fr fr
 
valutazione portogallo fr
valutazione portogallo frvalutazione portogallo fr
valutazione portogallo fr
 
valutazione portogallo it
valutazione portogallo itvalutazione portogallo it
valutazione portogallo it
 
valutazione portogallo pt
valutazione portogallo ptvalutazione portogallo pt
valutazione portogallo pt
 
Valutazione francia fr
Valutazione francia frValutazione francia fr
Valutazione francia fr
 
Valutazione italia it
Valutazione italia itValutazione italia it
Valutazione italia it
 
Valutazione francia it
Valutazione francia itValutazione francia it
Valutazione francia it
 
Valutazione italia fr
Valutazione italia frValutazione italia fr
Valutazione italia fr
 
Pei portogallo pt
Pei portogallo ptPei portogallo pt
Pei portogallo pt
 
Pei portogallo it
Pei portogallo itPei portogallo it
Pei portogallo it
 
Pei portogallo fr
Pei portogallo frPei portogallo fr
Pei portogallo fr
 
Pei portogallo (pt)
Pei portogallo (pt)Pei portogallo (pt)
Pei portogallo (pt)
 
Pei portogallo (it)
Pei portogallo (it)Pei portogallo (it)
Pei portogallo (it)
 
Pei portogallo (fr)
Pei portogallo (fr)Pei portogallo (fr)
Pei portogallo (fr)
 

Último

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
Cyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdfCyberprint. Dark Pink Apt Group [EN].pdf
Cyberprint. Dark Pink Apt Group [EN].pdf
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 

WebNetConf 2012 - Single Page Apps

  • 1. Single Page Apps HTML5, ASP.NET Web API, Knockout Fabrizio Iezzoni @fabrizioiezzoni
  • 2. Thanks to the sponsors
  • 3. What’s a SPA? • A rich and responsive web app built with HTML5, CSS and JavaScript • Fits in a single page (but is not a strict requirement) providing a “fluid” experience without full page loadings • All necessary code is loaded once (bootstrap) • Persists the state on the client
  • 4. SPAs are Everywhere • Gmail (and many other Google services like Analytics, Docs, etc) • Windows Azure Management Portal • Facebook and Twitter • Hipmunk • Trello • CloudDocument • Apple iCloud
  • 5. SPA Architecture Visible UI Web UI HTML/CSS HTML/CSS/JS Data services JSON/XML Application layer Navigation JavaScript APIs Data access layer JavaScript Local storage Server Client
  • 6. Frameworks and Libraries • Building a SPA without the proper tools is hard • Many frameworks and libraries emerged: – AngularJS, BackboneJS, BatmanJS, CanJS, Ember, KnockoutJS, Meteor, Spine • All adopt some sort of MV* pattern • Templating: DOM-based vs string-based • Some components are integrated (or optional), other must be added using external libraries (for example model/data storage or routing)
  • 7. Knockout.js • Developed and mantained by Steve Anderson (formerly ASP.NET team member) • Open Source project (NOT Microsoft) • It’s part of the ASP.NET MVC 4 template • Model-View-ViewModel (MVVM) pattern • Commanding, Change Tracking, Templating and Validation • All the rest must be integrated with other libraries
  • 8. Demo app: SPAtube • Very simple but complete SPA • Youtube player with a simple database for storing private playlists and membership data • Source code on GitHub: https://github.com/popapps/SPAtube • Live app on AppHarbor: http://spatube.apphb.com/
  • 9. SPAtube: ingredients DOM jQuery others UI Twitter Bootstrap Underscore.js Data binding MVVM Knockout.js Toastr AJAX, data push/pull, client Amplify.js Moment.js storage, pub/sub Nav / History Sammy.js Dependency resolution Require.js
  • 10. Please rate this session Scan the code, go online, rate this session