SlideShare a Scribd company logo
1 of 17
Download to read offline
Aditya Gaur


Mentor: Apurba Nath
What?
   Yahoo User Interface
   Pronounced “Why-you-eye” or “yooey”
   Launched in Feb 2006
   It is a collection of javascript and css resources
  Simplifies building web applications
 Provides ready to use, configurable components
  such as datatable, charts, dialog boxes and other
  widgets.
YUI global object
 Starting point of YUI


 Dependency for all YUI implementation


 Instantiable object- can create as many instances
as we need
Putting YUI on Page (1/3)
<script type="text/javascript"
src="http://yui.yahooapis.com/3.0.0pr1/build/yui/yui-
min.js"></script>



                                             anim       dd
      Y UI Object
           +               http request
     Loader Utility
                                            node        json
Putting YUI on Page (1/3)
 YUI().use('node', function(Y) {
   Y.Node.get('#demo');
 });




    <script type="text/javascript" src="http://
    yui.yahooapis.com/combo?3.0.0pr1/build/oop/oop-
    min.js&3.0.0pr1/build/event/event-min.js&3.0.0pr1/
    build/dom/dom-min.js&3.0.0pr1/build/node/node-
    min.js"></script>


REUSE : If any of the modules is already present on the page,
then http request is not send
Putting YUI on Page (2/3)
  <script type="text/javascript"
  src="http://yui.yahooapis.com/3.0.0pr1/combo?build/yui/yui-
  base.js"></script>



                                                       anim     dd

Y UI Object                  Loader
              http request    Utility   http request

                                                       node     json
Putting YUI on Page (3/3)
The Classical way:
  <script type="text/javascript" src="http://
  yui.yahooapis.com/combo?3.0.0pr1/build/yui-base/yui-
  base-min.js&3.0.0pr1/build/oop/oop-min.js&3.0.0pr1/
  build/event/event-min.js&3.0.0pr1/build/dom/dom-
  min.js&3.0.0pr1/build/node/node-min.js"></script>



  YUI().use('*', function(Y) {
      Y.get('#demo');
  });
YUI global object: Advantages
 Instance based: Sandboxing
   o Each instance is separate
   o Multiple applications per page
   o Secure mashups
 Dynamic
   o Since loader is built into core so we don’t have
     to statically include all modules
 Namespace – Avoiding naming conflict
YUI3 vs YUI2
Global Variable
 YAHOO replaced by YUI


 Reasons:
     Some people don’t like YAHOO in their code
     Both the YUI 2 and YUI 3 code can co exist
Modularity
Modularity is good but “Sub Modularity” is better.


                               Datasource
                                   Y UI 2



                                   Y UI 3
Datasource   Datasource   Datasource    Datasource   Datasource   Datasource
    io          Local       P olling        Get      jsonschema    function
Loader
 In YUI 3 the loader is built into the core.


 In YUI 2, we have a loader utility:
  var loader = new YAHOO.util.YUILoader();
Loader (YUI 2)



                                     Module 1
<script src="module1.js"></script>



<script src="module1.js"></script>   Module 2




                                     Module 3
<script src="module1.js"></script>
Loader (YUI 3)


    YUI().use("module1“, "module2“ , "module3“,)



                       Y UI seed file




            Module 1        Module 2    Module 3
That’s it for YUI
mViewer Updates

    mViewer
Thank You

More Related Content

Viewers also liked

Viewers also liked (6)

Wwaipt prior knowledge
Wwaipt prior knowledgeWwaipt prior knowledge
Wwaipt prior knowledge
 
CRM privacy whitepaper final
CRM privacy whitepaper finalCRM privacy whitepaper final
CRM privacy whitepaper final
 
Grails
GrailsGrails
Grails
 
Prototype
PrototypePrototype
Prototype
 
WMB
WMBWMB
WMB
 
Javascript
JavascriptJavascript
Javascript
 

Similar to Yui intro

Server Side JavaScript - You ain't seen nothing yet
Server Side JavaScript - You ain't seen nothing yetServer Side JavaScript - You ain't seen nothing yet
Server Side JavaScript - You ain't seen nothing yet
Tom Croucher
 
Liferay UI (R)evolution
Liferay UI (R)evolutionLiferay UI (R)evolution
Liferay UI (R)evolution
Zeno Rocha
 

Similar to Yui intro (20)

Running YUI 3 on Node.js - JSConf 2010
Running YUI 3 on Node.js - JSConf 2010Running YUI 3 on Node.js - JSConf 2010
Running YUI 3 on Node.js - JSConf 2010
 
Server Side JavaScript - You ain't seen nothing yet
Server Side JavaScript - You ain't seen nothing yetServer Side JavaScript - You ain't seen nothing yet
Server Side JavaScript - You ain't seen nothing yet
 
JavaScript Everywhere! Creating a 100% JavaScript web stack
JavaScript Everywhere! Creating a 100% JavaScript web stackJavaScript Everywhere! Creating a 100% JavaScript web stack
JavaScript Everywhere! Creating a 100% JavaScript web stack
 
Hack U - YUI - 2012 IIT Kharagpur
Hack U - YUI - 2012 IIT KharagpurHack U - YUI - 2012 IIT Kharagpur
Hack U - YUI - 2012 IIT Kharagpur
 
Running YUI 3 on Node.js - BayJax
Running YUI 3 on Node.js - BayJaxRunning YUI 3 on Node.js - BayJax
Running YUI 3 on Node.js - BayJax
 
YUI for your Hacks
YUI for your Hacks YUI for your Hacks
YUI for your Hacks
 
YUI3 - IIT Madras HackU
YUI3 - IIT Madras HackU YUI3 - IIT Madras HackU
YUI3 - IIT Madras HackU
 
YUI 3
YUI 3YUI 3
YUI 3
 
YUI3 and AlloyUI Introduction for Pernambuco.JS 2012
YUI3 and AlloyUI Introduction for Pernambuco.JS 2012YUI3 and AlloyUI Introduction for Pernambuco.JS 2012
YUI3 and AlloyUI Introduction for Pernambuco.JS 2012
 
YUI Basics
YUI BasicsYUI Basics
YUI Basics
 
YUIConf2013: Introducing The "Modown" Project
YUIConf2013: Introducing The "Modown" ProjectYUIConf2013: Introducing The "Modown" Project
YUIConf2013: Introducing The "Modown" Project
 
Hack with YUI
Hack with YUIHack with YUI
Hack with YUI
 
JS Loading strategies
JS Loading strategiesJS Loading strategies
JS Loading strategies
 
Embracing YUI3 and Frontend Perf
Embracing YUI3 and Frontend PerfEmbracing YUI3 and Frontend Perf
Embracing YUI3 and Frontend Perf
 
YUI Test The Next Generation (YUIConf 2010)
YUI Test The Next Generation (YUIConf 2010)YUI Test The Next Generation (YUIConf 2010)
YUI Test The Next Generation (YUIConf 2010)
 
Let's run JavaScript Everywhere
Let's run JavaScript EverywhereLet's run JavaScript Everywhere
Let's run JavaScript Everywhere
 
Starting with jQuery
Starting with jQueryStarting with jQuery
Starting with jQuery
 
Liferay UI (R)evolution
Liferay UI (R)evolutionLiferay UI (R)evolution
Liferay UI (R)evolution
 
Security testing of YUI powered applications
Security testing of YUI powered applicationsSecurity testing of YUI powered applications
Security testing of YUI powered applications
 
YUI on the go
YUI on the goYUI on the go
YUI on the go
 

Recently uploaded

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
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
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
 

Recently uploaded (20)

HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
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
 
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
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
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
 
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...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
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...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 

Yui intro

  • 2. What?  Yahoo User Interface  Pronounced “Why-you-eye” or “yooey”  Launched in Feb 2006  It is a collection of javascript and css resources  Simplifies building web applications  Provides ready to use, configurable components such as datatable, charts, dialog boxes and other widgets.
  • 3. YUI global object  Starting point of YUI  Dependency for all YUI implementation  Instantiable object- can create as many instances as we need
  • 4. Putting YUI on Page (1/3) <script type="text/javascript" src="http://yui.yahooapis.com/3.0.0pr1/build/yui/yui- min.js"></script> anim dd Y UI Object + http request Loader Utility node json
  • 5. Putting YUI on Page (1/3) YUI().use('node', function(Y) { Y.Node.get('#demo'); }); <script type="text/javascript" src="http:// yui.yahooapis.com/combo?3.0.0pr1/build/oop/oop- min.js&3.0.0pr1/build/event/event-min.js&3.0.0pr1/ build/dom/dom-min.js&3.0.0pr1/build/node/node- min.js"></script> REUSE : If any of the modules is already present on the page, then http request is not send
  • 6. Putting YUI on Page (2/3) <script type="text/javascript" src="http://yui.yahooapis.com/3.0.0pr1/combo?build/yui/yui- base.js"></script> anim dd Y UI Object Loader http request Utility http request node json
  • 7. Putting YUI on Page (3/3) The Classical way: <script type="text/javascript" src="http:// yui.yahooapis.com/combo?3.0.0pr1/build/yui-base/yui- base-min.js&3.0.0pr1/build/oop/oop-min.js&3.0.0pr1/ build/event/event-min.js&3.0.0pr1/build/dom/dom- min.js&3.0.0pr1/build/node/node-min.js"></script> YUI().use('*', function(Y) { Y.get('#demo'); });
  • 8. YUI global object: Advantages  Instance based: Sandboxing o Each instance is separate o Multiple applications per page o Secure mashups  Dynamic o Since loader is built into core so we don’t have to statically include all modules  Namespace – Avoiding naming conflict
  • 10. Global Variable  YAHOO replaced by YUI  Reasons:  Some people don’t like YAHOO in their code  Both the YUI 2 and YUI 3 code can co exist
  • 11. Modularity Modularity is good but “Sub Modularity” is better. Datasource Y UI 2 Y UI 3 Datasource Datasource Datasource Datasource Datasource Datasource io Local P olling Get jsonschema function
  • 12. Loader  In YUI 3 the loader is built into the core.  In YUI 2, we have a loader utility: var loader = new YAHOO.util.YUILoader();
  • 13. Loader (YUI 2) Module 1 <script src="module1.js"></script> <script src="module1.js"></script> Module 2 Module 3 <script src="module1.js"></script>
  • 14. Loader (YUI 3) YUI().use("module1“, "module2“ , "module3“,) Y UI seed file Module 1 Module 2 Module 3
  • 16. mViewer Updates mViewer