SlideShare une entreprise Scribd logo
1  sur  31
A powerful javascript framework
                                   by
                  Vincenzo Ferrari




     License : Creative Commons (Attribution , Share Alike) 3.0 Generic
License


  Open Source License (GPLv3)


  Commercial Software License




                 More info at
 http://www.sencha.com/products/extjs/license/


License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Provided


Familiar and simple to learn (cool documentation)
Fast to develop
Easy to debug
Painless to deploy
Well-organized (powerful mvc architecture)
Extensible (plugin support)
Maintanable




      License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget


Grids                      Drag&Drop                                    QuickTips
Charts                     Toolbars and Menus                           Progress Bar
Tabs                       ComboBox                                     Buttons
Windows                    Data View                                    Spotlight
Trees                      Forms                                        Slider
Layout Managers            Text Editors
Drawing                    Panels




         License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Grids




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Charts




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Tabs




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Windows




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Trees




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Menus




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Toolbars




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Widget - Forms




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Base
Class System                               Application Architecture
  Ext                                            Ext.app.Application
  Ext.Base                                       Ext.app.Controller
  Ext.Class                                      Ext.ModelManager
  Ext.Loader                                     Ext.state.CookieProvider




DOM & Browser                              Support
  Ext.DomQuery                                   Ext.is
  Ext.core.Element                               Ext.env.Browser
  Ext.Img                                        Ext.env.OS
  Ext.Ajax                                       Ext.supports
  Ext.data.JsonP                                 Ext.Version


     License : Creative Commons (Attribution , Share Alike) 3.0 Generic
View
Containers & Panels                                Layouts
  Ext.container.Viewport                                 Ext.layout.Layout
  Ext.panel.Panel                                        Ext.layout.container.Accordion
  Ext.tab.Panel                                          Ext.layout.container.Anchor
  Ext.tree.Panel                                         Ext.layout.container.HBox
  Ext.grid.Panel                                         Ext.layout.container.VBox




                       Draw
                             Ext.draw.Color
                             Ext.draw.Component
                             Ext.draw.Sprite
                             Ext.draw.Surface



             License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Components
Form                             Charts                                Tree
  Ext.form.Basic                       Ext.chart.Chart                       Ext.tree.Panel
  Ext.form.field.Base                  Ext.chart.Legend                      Ext.data.Tree
  Ext.form.field.Text                  Ext.chart.Label                       Ext.data.TreeStore
  Ext.form.field.TextArea              Ext.chart.Navigation                  Ext.tree.View



Toolbar                          Grid                                  Menu
  Ext.toolbar.Toolbar                  Ext.grid.Panel                        Ext.menu.Menu
  Ext.toolbar.Item                     Ext.view.Table                        Ext.menu.CheckItem
  Ext.toolbar.Separator                Ext.view.BoundList                    Ext.menu.Manager
  Ext.toolbar.TextItem                 Ext.view.View                         Ext.menu.Separator




               License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Data
Models                                     Proxies
  Ext.data.Model                                 Ext.data.proxy.Ajax
  Ext.data.Field                                 Ext.data.proxy.JsonP
  Ext.data.validations                           Ext.data.proxy.Rest
  Ext.data.Errors                                Ext.data.proxy.LocalStorage




Stores                                     Readers & Writers
  Ext.data.Store                                 Ext.data.reader.Reader
  Ext.data.StoreManager                          Ext.data.reader.Xml
  Ext.data.DirectStore                           Ext.data.writer.Writer
  Ext.data.AbstractStore                         Ext.data.writer.Xml



     License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Data Package




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Model




License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Utilities
Native Extensions                                  Utility
  Ext.Array                                              Ext.util.Sorter
  Ext.Object                                             Ext.util.Sortable
  Ext.String                                             Ext.util.HashMap
  Ext.JSON                                               Ext.util.Filter
  Ext.Function




                       Events
                             Ext.TaskManager
                             Ext.EventManager
                             Ext.EventObject
                             Ext.util.Observable



             License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext
The Ext namespace (global object) encapsulates all classes, singletons, and
utility methods provided by Sencha's libraries.


      Properties                                                Methods
         isChrome                                                  create
         isSafari                                                  each
         isIE                                                      get
         isOpera                                                   getCmp
         isGecko                                                   getDom
         isWebKit                                                  getStore
         isLinux                                                   isArray
         isMac                                                     isEmpty
         isWindows                                                 isObject
                                                                   onDocumentReady
                                                                   onReady



               License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext - Examples
Ext.create
    var win = Ext.create ('Ext.window.Window', {id: 'win1'});

Ext.each
    var operatingSystems = ['Linux', 'Mac', 'Windows'];
    Ext.each (operatingSystems, function (item, index, array) {
        alert ('Current OS is: ' + item);
    });

Ext.get
    <div id=”chatlog”>......</div>
    var cl = Ext.get ('chatlog');
    cl.setVisible (false);

Ext.getCmp
    var win = Ext.getCmp ('win1');


                License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext.Class
 Handles class creation throughout the whole framework.


Basic Syntax
   Ext.define ('MyClass', {prop: val, ...});

Inheritance
   Ext.define ('MyClass', {extend: 'OtherClass', …});

Mixins
   Ext.define ('MyClass', {mixins: {OtherClass: 'OtherClass'}, …});

Config
   Ext.define ('MyClass', {config: {prop: val}, …});

Statics
   Ext.define ('MyClass', {statics: {prop: val}, …});


      License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext.Class – Example 1
Basic Syntax                                Config
   Ext.define ('KnowsPhp', {                      Ext.define ('Person', {
       knows: function () {                              config: {
           alert ('I know PHP!');                             name: '' ,
       }                                                      age: 0
   });                                                   },
                                                         constructor: function (cfg) {
    Ext.define ('KnowsRuby', {                                this.initConfig (cfg);
        knows: function () {                                  return this;
            alert ('I know Ruby!');                      },
        }                                                applyName: function (name) {
    });                                                       if (name.length === 0)
                                                                    alert ('Error!');
    Ext.define ('KnowsPython', {                              else {
        knows: function () {                                        this.name = name;
            alert ('I know Python!');                               return this.name;
        }                                                     }
    });                                                  }
                                                  });
                License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext.Class – Example 2
Inheritance                        Mixins
   Ext.define ('Thief', {             Ext.define ('Developer', {
        extend: 'Person' ,                extend: 'Person' ,
        steal: function () {              mixins: {
            alert ('#Stealing#');             KnowsPhp: 'KnowsPhp' ,
        }                                     KnowsRuby: 'KnowsRuby' ,
   });                                        KnowsPython: 'KnowsPython'
                                          },
    Ext.define ('Burglar', {              knowledge: function () {
        extend: 'Person' ,                    alert ('Follows what I know:');
        lockpick: function () {               this.mixins.KnowsPhp.knows ();
            alert ('#Lockpicking#');          this.mixins.KnowsRuby.knows ();
        }                                     this.mixins.KnowsPython.knows ();
    });                                   }
                                      });



                License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext.Class – Example 3
Statics
    Ext.define ('PCCreator', {           var dell = PCCreator.factory ('Dell');
        statics: {                       var asus = PCCreator.factory ('Asus');
            computerCounter: 0 ,         var hp = PCCreator.factory ('HP');
            factory: function (name) {
                 return new this (name); Alert (dell.name);
            }                            Alert (asus.name);
        },                               Alert (hp.name);
        config: {
            name: ''                     Alert (PCCreator.computerCounter);
        },
        constructor: function (cfg) {
            this.initConfig (cfg);
            this.self.computerCounter++;
            return this;
        }
    });

               License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Ext.Loader
Ext.Loader is the heart of the new dynamic dependency loading
capability in Ext JS 4+. It is most commonly used via the Ext.require
shorthand. Ext.Loader supports both asynchronous and synchronous
loading approaches.
Asynchronous Loading
Advantages
    Cross-domain                                                 Hybrid Solution?
    No web server needed                                         Yes, we can!
    Best possible debugging
Disadvantages
    Dependencies need to be specified before-hand

Synchronous Loading on Demand
Advantages
    There's no need to specify dependencies before-hand
Disadvantages
    Not as good debugging experience
    Must be from the same domain due to XHR restriction
    Need a web server


                  License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Requirements

Web Browsers
   Google Chrome 10+
   Apple Safari 5+
   Mozilla Firefox 4+

Web Server (is not a requirement but is highly recommended)
   Apache (recommended)

ExtJS 4 SDK
   Download at http://www.sencha.com/products/extjs




      License : Creative Commons (Attribution , Share Alike) 3.0 Generic
MVC Architecture
Ext JS 4 comes with a new application architecture that not only organizes
your code but reduces the amount you have to write.

Model
Is a collection of fields and their data (e.g. a User model with username and
password fields). Models know how to persist themselves through the data
package, and can be linked to other models through associations. Models are
normally used with Stores to present data into grids and other components.

View
Is any type of component - grids, trees and panels are all views.

Controllers
Are special places to put all of the code that makes your app work - whether that's
rendering views, instantiating Models, or any other app logic.




               License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Enough!



Ok, you showed us what you know: great, you did your
                   homework!
           Now we want to see some code!




        License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Build my WebApp
What do I have to know to build my first web application?

                               File Structure


                  /var/www/
                                 index.html
                                 app.js
                                 ext/
                                 app/
                                                 controller/
                                                 model/
                                                 store/
                                                 view/



        License : Creative Commons (Attribution , Share Alike) 3.0 Generic
Credits


             Vincenzo Ferrari
            wilk3ert@gmail.com




License : Creative Commons (Attribution , Share Alike) 3.0 Generic

Contenu connexe

Similaire à ExtJS: a powerful Javascript framework

Ext JS 4 Architecture
Ext JS 4 ArchitectureExt JS 4 Architecture
Ext JS 4 ArchitectureSencha
 
Dojo - from web page to web apps
Dojo - from web page to web appsDojo - from web page to web apps
Dojo - from web page to web appsyoavrubin
 
Cross-Platform Native Mobile Development with Eclipse
Cross-Platform Native Mobile Development with EclipseCross-Platform Native Mobile Development with Eclipse
Cross-Platform Native Mobile Development with EclipsePeter Friese
 
WPF Windows Presentation Foundation A detailed overview Version1.2
WPF Windows Presentation Foundation A detailed overview Version1.2WPF Windows Presentation Foundation A detailed overview Version1.2
WPF Windows Presentation Foundation A detailed overview Version1.2Shahzad
 
Architecture of the Web browser
Architecture of the Web browserArchitecture of the Web browser
Architecture of the Web browserSabin Buraga
 
Js info vis_toolkit
Js info vis_toolkitJs info vis_toolkit
Js info vis_toolkitnikhilyagnic
 
Opensource gis development - part 5
Opensource gis development - part 5Opensource gis development - part 5
Opensource gis development - part 5Andrea Antonello
 
130614 sebastiano panichella - mining source code descriptions from develo...
130614   sebastiano panichella -  mining source code descriptions from develo...130614   sebastiano panichella -  mining source code descriptions from develo...
130614 sebastiano panichella - mining source code descriptions from develo...Ptidej Team
 
Cross Platform Mobile App Development - An Introduction to Sencha Touch
Cross Platform Mobile App Development - An Introduction to Sencha TouchCross Platform Mobile App Development - An Introduction to Sencha Touch
Cross Platform Mobile App Development - An Introduction to Sencha TouchFolio3 Software
 
Android101 - Intro and Basics
Android101 - Intro and BasicsAndroid101 - Intro and Basics
Android101 - Intro and Basicsjromero1214
 
Ext JS 4.0 - Creating extensions, plugins and components
Ext JS 4.0 - Creating extensions, plugins and componentsExt JS 4.0 - Creating extensions, plugins and components
Ext JS 4.0 - Creating extensions, plugins and componentsPatrick Sheridan
 
Googleappengineintro 110410190620-phpapp01
Googleappengineintro 110410190620-phpapp01Googleappengineintro 110410190620-phpapp01
Googleappengineintro 110410190620-phpapp01Tony Frame
 
VRE Cancer Imaging BL RIC Workshop 22032011
VRE Cancer Imaging BL RIC Workshop 22032011VRE Cancer Imaging BL RIC Workshop 22032011
VRE Cancer Imaging BL RIC Workshop 22032011djmichael156
 
The Java Content Repository
The Java Content RepositoryThe Java Content Repository
The Java Content Repositorynobby
 
Beyond the Basics, Debugging with Firebug and Web Inspector
Beyond the Basics, Debugging with Firebug and Web InspectorBeyond the Basics, Debugging with Firebug and Web Inspector
Beyond the Basics, Debugging with Firebug and Web InspectorSteven Roussey
 
Windows 8 für .net Entwickler
Windows 8 für .net EntwicklerWindows 8 für .net Entwickler
Windows 8 für .net EntwicklerPatric Boscolo
 
Hacking Windows IPC
Hacking Windows IPCHacking Windows IPC
Hacking Windows IPCgueste041bc
 

Similaire à ExtJS: a powerful Javascript framework (20)

Ext JS 4 Architecture
Ext JS 4 ArchitectureExt JS 4 Architecture
Ext JS 4 Architecture
 
Dojo - from web page to web apps
Dojo - from web page to web appsDojo - from web page to web apps
Dojo - from web page to web apps
 
Cross-Platform Native Mobile Development with Eclipse
Cross-Platform Native Mobile Development with EclipseCross-Platform Native Mobile Development with Eclipse
Cross-Platform Native Mobile Development with Eclipse
 
WPF Windows Presentation Foundation A detailed overview Version1.2
WPF Windows Presentation Foundation A detailed overview Version1.2WPF Windows Presentation Foundation A detailed overview Version1.2
WPF Windows Presentation Foundation A detailed overview Version1.2
 
Architecture of the Web browser
Architecture of the Web browserArchitecture of the Web browser
Architecture of the Web browser
 
Js info vis_toolkit
Js info vis_toolkitJs info vis_toolkit
Js info vis_toolkit
 
Opensource gis development - part 5
Opensource gis development - part 5Opensource gis development - part 5
Opensource gis development - part 5
 
130614 sebastiano panichella - mining source code descriptions from develo...
130614   sebastiano panichella -  mining source code descriptions from develo...130614   sebastiano panichella -  mining source code descriptions from develo...
130614 sebastiano panichella - mining source code descriptions from develo...
 
Cross Platform Mobile App Development - An Introduction to Sencha Touch
Cross Platform Mobile App Development - An Introduction to Sencha TouchCross Platform Mobile App Development - An Introduction to Sencha Touch
Cross Platform Mobile App Development - An Introduction to Sencha Touch
 
Android101 - Intro and Basics
Android101 - Intro and BasicsAndroid101 - Intro and Basics
Android101 - Intro and Basics
 
backend
backendbackend
backend
 
backend
backendbackend
backend
 
Ext JS 4.0 - Creating extensions, plugins and components
Ext JS 4.0 - Creating extensions, plugins and componentsExt JS 4.0 - Creating extensions, plugins and components
Ext JS 4.0 - Creating extensions, plugins and components
 
COinS (eng version)
COinS (eng version)COinS (eng version)
COinS (eng version)
 
Googleappengineintro 110410190620-phpapp01
Googleappengineintro 110410190620-phpapp01Googleappengineintro 110410190620-phpapp01
Googleappengineintro 110410190620-phpapp01
 
VRE Cancer Imaging BL RIC Workshop 22032011
VRE Cancer Imaging BL RIC Workshop 22032011VRE Cancer Imaging BL RIC Workshop 22032011
VRE Cancer Imaging BL RIC Workshop 22032011
 
The Java Content Repository
The Java Content RepositoryThe Java Content Repository
The Java Content Repository
 
Beyond the Basics, Debugging with Firebug and Web Inspector
Beyond the Basics, Debugging with Firebug and Web InspectorBeyond the Basics, Debugging with Firebug and Web Inspector
Beyond the Basics, Debugging with Firebug and Web Inspector
 
Windows 8 für .net Entwickler
Windows 8 für .net EntwicklerWindows 8 für .net Entwickler
Windows 8 für .net Entwickler
 
Hacking Windows IPC
Hacking Windows IPCHacking Windows IPC
Hacking Windows IPC
 

Dernier

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024TopCSSGallery
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Nikki Chapple
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesManik S Magar
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...itnewsafrica
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 

Dernier (20)

Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 

ExtJS: a powerful Javascript framework

  • 1. A powerful javascript framework by Vincenzo Ferrari License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 2. License Open Source License (GPLv3) Commercial Software License More info at http://www.sencha.com/products/extjs/license/ License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 3. Provided Familiar and simple to learn (cool documentation) Fast to develop Easy to debug Painless to deploy Well-organized (powerful mvc architecture) Extensible (plugin support) Maintanable License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 4. Widget Grids Drag&Drop QuickTips Charts Toolbars and Menus Progress Bar Tabs ComboBox Buttons Windows Data View Spotlight Trees Forms Slider Layout Managers Text Editors Drawing Panels License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 5. Widget - Grids License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 6. Widget - Charts License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 7. Widget - Tabs License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 8. Widget - Windows License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 9. Widget - Trees License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 10. Widget - Menus License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 11. Widget - Toolbars License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 12. Widget - Forms License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 13. Base Class System Application Architecture Ext Ext.app.Application Ext.Base Ext.app.Controller Ext.Class Ext.ModelManager Ext.Loader Ext.state.CookieProvider DOM & Browser Support Ext.DomQuery Ext.is Ext.core.Element Ext.env.Browser Ext.Img Ext.env.OS Ext.Ajax Ext.supports Ext.data.JsonP Ext.Version License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 14. View Containers & Panels Layouts Ext.container.Viewport Ext.layout.Layout Ext.panel.Panel Ext.layout.container.Accordion Ext.tab.Panel Ext.layout.container.Anchor Ext.tree.Panel Ext.layout.container.HBox Ext.grid.Panel Ext.layout.container.VBox Draw Ext.draw.Color Ext.draw.Component Ext.draw.Sprite Ext.draw.Surface License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 15. Components Form Charts Tree Ext.form.Basic Ext.chart.Chart Ext.tree.Panel Ext.form.field.Base Ext.chart.Legend Ext.data.Tree Ext.form.field.Text Ext.chart.Label Ext.data.TreeStore Ext.form.field.TextArea Ext.chart.Navigation Ext.tree.View Toolbar Grid Menu Ext.toolbar.Toolbar Ext.grid.Panel Ext.menu.Menu Ext.toolbar.Item Ext.view.Table Ext.menu.CheckItem Ext.toolbar.Separator Ext.view.BoundList Ext.menu.Manager Ext.toolbar.TextItem Ext.view.View Ext.menu.Separator License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 16. Data Models Proxies Ext.data.Model Ext.data.proxy.Ajax Ext.data.Field Ext.data.proxy.JsonP Ext.data.validations Ext.data.proxy.Rest Ext.data.Errors Ext.data.proxy.LocalStorage Stores Readers & Writers Ext.data.Store Ext.data.reader.Reader Ext.data.StoreManager Ext.data.reader.Xml Ext.data.DirectStore Ext.data.writer.Writer Ext.data.AbstractStore Ext.data.writer.Xml License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 17. Data Package License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 18. Model License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 19. Utilities Native Extensions Utility Ext.Array Ext.util.Sorter Ext.Object Ext.util.Sortable Ext.String Ext.util.HashMap Ext.JSON Ext.util.Filter Ext.Function Events Ext.TaskManager Ext.EventManager Ext.EventObject Ext.util.Observable License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 20. Ext The Ext namespace (global object) encapsulates all classes, singletons, and utility methods provided by Sencha's libraries. Properties Methods isChrome create isSafari each isIE get isOpera getCmp isGecko getDom isWebKit getStore isLinux isArray isMac isEmpty isWindows isObject onDocumentReady onReady License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 21. Ext - Examples Ext.create var win = Ext.create ('Ext.window.Window', {id: 'win1'}); Ext.each var operatingSystems = ['Linux', 'Mac', 'Windows']; Ext.each (operatingSystems, function (item, index, array) { alert ('Current OS is: ' + item); }); Ext.get <div id=”chatlog”>......</div> var cl = Ext.get ('chatlog'); cl.setVisible (false); Ext.getCmp var win = Ext.getCmp ('win1'); License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 22. Ext.Class Handles class creation throughout the whole framework. Basic Syntax Ext.define ('MyClass', {prop: val, ...}); Inheritance Ext.define ('MyClass', {extend: 'OtherClass', …}); Mixins Ext.define ('MyClass', {mixins: {OtherClass: 'OtherClass'}, …}); Config Ext.define ('MyClass', {config: {prop: val}, …}); Statics Ext.define ('MyClass', {statics: {prop: val}, …}); License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 23. Ext.Class – Example 1 Basic Syntax Config Ext.define ('KnowsPhp', { Ext.define ('Person', { knows: function () { config: { alert ('I know PHP!'); name: '' , } age: 0 }); }, constructor: function (cfg) { Ext.define ('KnowsRuby', { this.initConfig (cfg); knows: function () { return this; alert ('I know Ruby!'); }, } applyName: function (name) { }); if (name.length === 0) alert ('Error!'); Ext.define ('KnowsPython', { else { knows: function () { this.name = name; alert ('I know Python!'); return this.name; } } }); } }); License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 24. Ext.Class – Example 2 Inheritance Mixins Ext.define ('Thief', { Ext.define ('Developer', { extend: 'Person' , extend: 'Person' , steal: function () { mixins: { alert ('#Stealing#'); KnowsPhp: 'KnowsPhp' , } KnowsRuby: 'KnowsRuby' , }); KnowsPython: 'KnowsPython' }, Ext.define ('Burglar', { knowledge: function () { extend: 'Person' , alert ('Follows what I know:'); lockpick: function () { this.mixins.KnowsPhp.knows (); alert ('#Lockpicking#'); this.mixins.KnowsRuby.knows (); } this.mixins.KnowsPython.knows (); }); } }); License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 25. Ext.Class – Example 3 Statics Ext.define ('PCCreator', { var dell = PCCreator.factory ('Dell'); statics: { var asus = PCCreator.factory ('Asus'); computerCounter: 0 , var hp = PCCreator.factory ('HP'); factory: function (name) { return new this (name); Alert (dell.name); } Alert (asus.name); }, Alert (hp.name); config: { name: '' Alert (PCCreator.computerCounter); }, constructor: function (cfg) { this.initConfig (cfg); this.self.computerCounter++; return this; } }); License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 26. Ext.Loader Ext.Loader is the heart of the new dynamic dependency loading capability in Ext JS 4+. It is most commonly used via the Ext.require shorthand. Ext.Loader supports both asynchronous and synchronous loading approaches. Asynchronous Loading Advantages Cross-domain Hybrid Solution? No web server needed Yes, we can! Best possible debugging Disadvantages Dependencies need to be specified before-hand Synchronous Loading on Demand Advantages There's no need to specify dependencies before-hand Disadvantages Not as good debugging experience Must be from the same domain due to XHR restriction Need a web server License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 27. Requirements Web Browsers Google Chrome 10+ Apple Safari 5+ Mozilla Firefox 4+ Web Server (is not a requirement but is highly recommended) Apache (recommended) ExtJS 4 SDK Download at http://www.sencha.com/products/extjs License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 28. MVC Architecture Ext JS 4 comes with a new application architecture that not only organizes your code but reduces the amount you have to write. Model Is a collection of fields and their data (e.g. a User model with username and password fields). Models know how to persist themselves through the data package, and can be linked to other models through associations. Models are normally used with Stores to present data into grids and other components. View Is any type of component - grids, trees and panels are all views. Controllers Are special places to put all of the code that makes your app work - whether that's rendering views, instantiating Models, or any other app logic. License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 29. Enough! Ok, you showed us what you know: great, you did your homework! Now we want to see some code! License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 30. Build my WebApp What do I have to know to build my first web application? File Structure /var/www/ index.html app.js ext/ app/ controller/ model/ store/ view/ License : Creative Commons (Attribution , Share Alike) 3.0 Generic
  • 31. Credits Vincenzo Ferrari wilk3ert@gmail.com License : Creative Commons (Attribution , Share Alike) 3.0 Generic