jquery mobile introduction

29
jQuery Mobile Dutch Mobile Conference 2012 June 9

Upload: joris-graaumans

Post on 20-Dec-2014

1.150 views

Category:

Technology


1 download

DESCRIPTION

jQuery Mobile IntroductionPresented at Dutch Mobile Conference, June 9, 2012www.mobileconference.nlLevel: beginner

TRANSCRIPT

Page 1: jQuery Mobile Introduction

jQuery Mobile!

Dutch Mobile Conference 2012!June 9!

Page 2: jQuery Mobile Introduction

Introduction!•  Joris Graaumans!•  Lecturer @ Fontys University of Applied

Sciences!•  Bachelor's program ICT & Media Design!– web development!–  interaction & visual design!– media strategy!

!

Page 3: jQuery Mobile Introduction

What  keeps  me  busy?  

Page 4: jQuery Mobile Introduction

Agenda  

•  Teaching  web  development  •  What  is  jQuery  Mobile?  •  jQuery  Mobile  Demo  

Page 5: jQuery Mobile Introduction

Teaching  Web  Development  

•  HTML  /  CSS  /  JavaScript  •  PHP  /  Web  APIs  •  Mobile  web  •  Augmented  /  Virtual  Reality  •  Flash  AcJonScript  3.0  

Page 6: jQuery Mobile Introduction

What is jQuery Mobile?  

"A  unified  user  interface  system  that  works  seamlessly  across  all  popular  mobile  device  pla4orms,  built  on  the  rock-­‐solid  jQuery  and  jQuery  UI  foundaJon."  

 •  Started  in  August  2010  •  Current  version:  1.1.0  –  April  13,  2012  •  jquerymobile.com  

6  

Page 7: jQuery Mobile Introduction

Design  principles  

•  User  Interface  System  – Mobile  Web  ApplicaJons  – HTML5  based  

•  One  single  app  or  site  – All  popular  mobile  device  pla\orms  – Tested  on  a  large  set  of  devices  and  pla\orms  

Page 8: jQuery Mobile Introduction

Design  principles  

•  "Super  easy  to  use"  – SemanJc  markup  – Use  regular  HTML  with  data-­‐*  a^ributes  

•  Flexible  – Themes  – CSS  styles  – ScripJng  

Page 9: jQuery Mobile Introduction

Examples ...!

Page 10: jQuery Mobile Introduction

jQuery  Mobile  Examples  

Page 11: jQuery Mobile Introduction

m.venraybloeit.nl/test  

Page 12: jQuery Mobile Introduction

cultuurbewust.nl  

Page 13: jQuery Mobile Introduction

All platforms?!

Page 14: jQuery Mobile Introduction

Test  setup  ...  

Page 15: jQuery Mobile Introduction

Cultuurbewust.nl  

Page 16: jQuery Mobile Introduction

test.bertvanelswijk.nl  

Page 17: jQuery Mobile Introduction

jQuery Mobile How To!

Page 18: jQuery Mobile Introduction

jQuery  How  To  

•  pages  –  content  –  header  –  footer  

•  list  views  •  page  transiJons  •  navigaJon  bars  •  forms  •  events    

Page 19: jQuery Mobile Introduction

index.html  

•  Simple  page  •  Fixed  header  and  footer  •  Theming    

Page 20: jQuery Mobile Introduction

index2.html  

Typically  used  for  navigaJon  between  pages  •  Basic  <ul>  and  <li>  elements    •  Listviews  – data-­‐role="listview"  –  inset  appearance:  data-­‐inset="true"  

•  Listheaders  – data-­‐divider-­‐theme  (on  the  <ul>  element)  

Page 21: jQuery Mobile Introduction

index3.html  

•  TransiJons  between  pages  •  Links:    <a href="#idOfThePage"> ... </a>!•  Links  are  loaded  with  Ajax  by  JQM  – page  transiJons  

•  Dialogs:  no  history  &  pop-­‐up  •  Different  transiJon  types  (pop,  slide,  etc)  

Page 22: jQuery Mobile Introduction

index4.html  

•  NavigaJon  bar:  data-role="navbar"  •  NavigaJon  bu^ons,  Go  back,  Go  Home  •  Icons  – data-­‐icon="home"  –   data-­‐icon="arrow-­‐l"  – data-­‐icon="plus"  – data-­‐icon="back"  – etc.  

Page 23: jQuery Mobile Introduction

index5.html  

•  Forms  •  Use  regular  HTML5  Forms  •  Improve  styling  – data-­‐role="fieldcontain"  

•  Group  a  set  of  controls  – data-­‐role="controlgroup"  

Page 24: jQuery Mobile Introduction

ScripJng  

•  Pageinit  /  pageshow  events  •  Form  submit  •  Page  transiJon  •  index6.html  

Page 25: jQuery Mobile Introduction

LimitaJons  of  jQuery  Mobile  

•  Try  it  and  find  out  •  Performance  •  jQuery  Mobile  does  not  try  to  mimic  –  iOS  – Android  – Windows    

•  NaJve  app?  – Use  PhoneGap  as  a  wrapper.  

Page 26: jQuery Mobile Introduction

Conclusions  

•  jQuery  Mobile  is  super  easy  to  use  – declaraJve  style  – not  very  different  from  wriJng  regular  HTML  

•  Builds  on  HTML  /  JQuery  /  jQuery  UI  •  Go  and  give  it  a  try!  

Page 27: jQuery Mobile Introduction

References  

•  h^p://jquerymobile.com/demos/1.1.0/docs/about/gemng-­‐started.html  

•  h^p://jquerymobile.com/themeroller/  

•  Tool  for  a  quick  GUI  setup:  h^p://codiqa.com/  

Page 28: jQuery Mobile Introduction

Please  fill  in  this  survey  

h^p://Jnyurl.com/appuex  

Page 29: jQuery Mobile Introduction

Contact  

•  [email protected]  •  @JorisGraaumans