Your SlideShare is downloading. ×
0
Chief Technology Officer Blueliner NY www.bluelinerny.com www.mahbubblog.com Md. Mahbubur Rahman
? What is Rich Internet Applications, Btw
Rich Internet Applications
Templates Again ?
Why JavaScript Templates ? JavaScript templates are rendered and cached client-side without sending an HTTP request to the...
Pushing Some loads to Client’s Computer
Flow of how JavaScript Templates work
HOW DO JAVASCRIPT TEMPLATES LOOK LIKE HTML  JSON <div class=&quot;entry&quot;> <h1> {{title}} </h1> {{#with author}} <h2>B...
HOW DO JAVASCRIPT TEMPLATES LOOK LIKE - 2  <script id=&quot;movieTemplate&quot; type=&quot;text/x-jquery-tmpl&quot;> <tr> ...
HOW DO JAVASCRIPT TEMPLATES LOOK LIKE - 3  < script type = &quot;text/javascript&quot; > var  movies  =   [{   Title :   &...
HOW DO JAVASCRIPT TEMPLATES LOOK LIKE – 4
Ways of Using Visitor’s PCs. Adobe Flash / Flex Google Gears Microsoft Silverlight HTML5
Let some computation be done by Client
Right AJAX Data Transport XML JSON HTML
Same Template  for Server side and Client Side Ex. Mustache, Handlebar JS Available in Ruby, JavaScript, Python, Erlang,  ...
Same Template  for Server side and Client Side (Contd.)
JS Templating Good when Loading all data from the server especially in rich list displays Adding or updating new items in ...
JavaScript Templating best suited for Stock Related apps Web Admin Panel Live Score Web Desktops Any AJAX Intensive app
Some JavaScript Templating Engines jQuery.View  ( https://github.com/BorisMoore/jsviews) jQuery View Renderer  ( https://g...
Upcoming SlideShare
Loading in...5
×

Taking Advantage of Client Side / JavsScript Templates in Rich Internet Applications

3,090

Published on

Published in: Technology, Business
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
3,090
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
33
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Transcript of "Taking Advantage of Client Side / JavsScript Templates in Rich Internet Applications"

  1. 1. Chief Technology Officer Blueliner NY www.bluelinerny.com www.mahbubblog.com Md. Mahbubur Rahman
  2. 2. ? What is Rich Internet Applications, Btw
  3. 3. Rich Internet Applications
  4. 4. Templates Again ?
  5. 5. Why JavaScript Templates ? JavaScript templates are rendered and cached client-side without sending an HTTP request to the server — in other words, they’re lightning fast. Speed benefits aside, JavaScript templates also afford us the opportunity to abstract the administrative UI into a simple JavaScript API. Rich and Faster User Experience Decrease the load on Server [ increase scalability ] Easy to Manage And.. Because the modern web browsers are very powerful
  6. 6. Pushing Some loads to Client’s Computer
  7. 7. Flow of how JavaScript Templates work
  8. 8. HOW DO JAVASCRIPT TEMPLATES LOOK LIKE HTML JSON <div class=&quot;entry&quot;> <h1> {{title}} </h1> {{#with author}} <h2>By {{firstName}} {{lastName}} </h2> {{/with}} </div> { title: &quot;My first post!&quot;, author: { firstName: &quot;Charles&quot;, lastName: &quot;Jolley&quot; } }
  9. 9. HOW DO JAVASCRIPT TEMPLATES LOOK LIKE - 2 <script id=&quot;movieTemplate&quot; type=&quot;text/x-jquery-tmpl&quot;> <tr> <td> {{=Title}} </td> <td> {{#if Languages}} Alternative languages: <em> {{=Languages}} </em>. {{else Subtitles}} Original language only... <br/>Subtitles in <em> {{=Subtitles}} </em>. {{else}} Original version only, without subtitles. {{/if}} </td> </tr> </script>
  10. 10. HOW DO JAVASCRIPT TEMPLATES LOOK LIKE - 3 < script type = &quot;text/javascript&quot; > var movies = [{ Title : &quot;Meet Joe Black&quot; , Languages : &quot;English and French&quot; , Subtitles : &quot;English&quot; }, { Title : &quot;Eyes Wide Shut&quot; , Subtitles : &quot;French and Spanish&quot; }, { Title : &quot;The Mighty&quot; }, { Title : &quot;City Hunter&quot; , Languages : &quot;Mandarin and Chinese&quot; }]; $ ( &quot;#movieList&quot; ). html ( $ ( &quot;#movieTemplate&quot; ). render ( movies )); </ script >
  11. 11. HOW DO JAVASCRIPT TEMPLATES LOOK LIKE – 4
  12. 12. Ways of Using Visitor’s PCs. Adobe Flash / Flex Google Gears Microsoft Silverlight HTML5
  13. 13. Let some computation be done by Client
  14. 14. Right AJAX Data Transport XML JSON HTML
  15. 15. Same Template for Server side and Client Side Ex. Mustache, Handlebar JS Available in Ruby, JavaScript, Python, Erlang, PHP, Perl, Objective-C, Java, .NET, Android, C++, Go, Lua, ooc, ActionScript, ColdFusion, Scala, Clojure, Fantom, CoffeeScript, D, and for node.js .
  16. 16. Same Template for Server side and Client Side (Contd.)
  17. 17. JS Templating Good when Loading all data from the server especially in rich list displays Adding or updating new items in lists Anywhere you need to add new complex content to the page Anything that requires client side HTML rendering
  18. 18. JavaScript Templating best suited for Stock Related apps Web Admin Panel Live Score Web Desktops Any AJAX Intensive app
  19. 19. Some JavaScript Templating Engines jQuery.View ( https://github.com/BorisMoore/jsviews) jQuery View Renderer ( https://github.com/BorisMoore/jsrender) Mustache ( http://mustache.github.com/) EJS ( http://embeddedjs.com/) PURE (http:// beebole.com/pure/) HandlebarJS ( http://www.handlebarsjs.com/) UnderscoreJS ( http://documentcloud.github.com/underscore/)
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×