SlideShare uma empresa Scribd logo
1 de 14
JS-TYPES
大綱
 htmlString
 Number

 Object
 Array
 PlainObject
font-size

HTMLSTRING
 A string is designated htmlString in jQuery documentation when it is used
to represent one or more DOM elements, typically to be created and
inserted in the document.

 For explicit parsing of a string to HTML, the $.parseHTML() method is
available as of jQuery 1.8
 // Appends <b>hello</b>:
 $( "<b>hello</b>" ).appendTo( "body" );

 // Appends <b>hello</b>:
 $( "<b>hello</b>bye" ).appendTo( "body" );

 // Syntax error, unrecognized expression: bye<b>hello</b>
 $( "bye<b>hello</b>" ).appendTo( "body" );

 // Appends bye<b>hello</b>:
 $( $.parseHTML( "bye<b>hello</b>" ) ).appendTo( "body" );

 // Appends <b>hello</b>wait<b>bye</b>:
 $( "<b>hello</b>wait<b>bye</b>" ).appendTo( "body" );

 For explicit parsing of a string to HTML, use the $.parseHTML()
font-size

NUMBER
The type of a number is "number".
typeof 12 // "number"
typeof 3.543 // "number“

if a number is zero, it defaults to false:
!0 // true
!!0 // false
!1 // false
!-1 // false

Due to the implementation of numbers as double-precision values,
the following result is not an error:
0.1 + 0.2 // 0.30000000000000004
font-size

NUMBER
 Parsing Numbers
 parseInt and parseFloat help parsing strings into numbers. Both do
some implicit conversion if the base isn't specified:







parseInt( "123" ) = 123 // (implicit decimal)
parseInt( "010" ) = 8 // (implicit octal)
parseInt( "0xCAFE" ) = 51966 // (implicit hexadecimal)
parseInt( "010", 10 ) = 10 // (explicit decimal)
parseInt( "11", 2 ) = 3 // (explicit binary)
parseFloat( "10.10" ) = 10.1
font-size

NUMBER
 Numbers to Strings
 When appending numbers to string, the result is always a string.
The operator is the same, so be careful: If you want to add
numbers and then append them to a string, put parentheses
around them:





"" + 1 + 2; // "12"
"" + ( 1 + 2 ); // "3"
"" + 0.0000001; // "1e-7"
parseInt( 0.0000001 ); // 1 (!) , 1e-7 parseInt() -> 1

 Or you use the String class provided by javascript, which try to
parse a value as string
 String( 1 ) + String( 2 ); // "12"
 String( 1 + 2 ); // "3"
font-size

NUMBER
 NaN and Infinity
 Parsing something that isn't a number results in NaN. isNaN helps
to detect those cases:
 parseInt( "hello", 10 ) // NaN
 isNaN( parseInt("hello", 10) ) // true

 Division by zero results in Infinity:
 1 / 0 // Infinity

 Both NaN and Infinity are of type "number":
 typeof NaN // "number"
 typeof Infinity // "number“
font-size

NUMBER
 Note that NaN compares in a strange way:
 NaN == NaN // false (!)

 But:
 Infinity == Infinity // true
font-size

OBJECT
Everything in JavaScript is an object
var x = {};
var y = {
name: "Pete",
age: 15

};

The type of an object is "object":
typeof {} // "object“

Use Dot or Array Notation to write and read properties
var obj = {

name: "Pete",
age: 15
};
for( key in obj ) {
alert( "key is " + [ key ] + ", value is " + obj[ key ] );
}

Note that for-in-loop can be spoiled by extending Object.prototype so take care when using other
libraries.Use jQuery.each(obj, function( key, value ))
font-size

OBJECT
An object, no matter if it has properties or not, never defaults to
false:
!{} // false
!!{} // true
font-size

ARRAY
Arrays in JavaScript are mutable lists with a few built-in methods. You can
define arrays using the array literal:
var x = [];
var y = [ 1, 2, 3 ];

The type of an array is "object":
typeof []; // "object"
typeof [ 1, 2, 3 ]; // "object“

Reading and writing elements to an array uses the array-notation:
x[ 0 ] = 1;
y[ 2 ] // 3

 The length property can also be used to add elements to the end of an array
var x = [];
x.push( 1 );
x[ x.length ] = 2;
x[1000] = 1; // x.length = 1000
font-size

ARRAY
jQuery provides a generic each function to iterate over element of arrays, as well as properties of
objects:
var x = [ 1, 2, 3 ];
jQuery.each( x, function( index, value ) {
console.log( "index", index, "value", value );
});

The length property can also be used to add elements to the end of an array. That is equivalent to
using the push-method:
var x = [ 0, 3, 1, 2 ];
x.reverse() // x = [ 2, 1, 3, 0 ]
x.join(" – ") // "2 - 1 - 3 - 0"
x.pop() // pop 0 , x= [ 2, 1, 3 ]
x.unshift( -1 ) // newlength 4 , x = [ -1, 2, 1, 3 ]
x.shift() // remove -1 , x = [ 2, 1, 3 ]
x.sort() // [ 1, 2, 3 ]
x.splice( 1, 2 ) // remove 2,3 , x =[1 ]
An array, no matter if it has elements or not, never defaults to false:
![] // false
!![] // true
font-size

PLAINOBJECT
The PlainObject type is a JavaScript object containing zero or more keyvalue pairs. The plain object is, in other words, an Object object. It is
designated "plain" in jQuery documentation to distinguish it from other
kinds of JavaScript objects: for example, null, user-defined arrays, and host
objects such as document, all of which have a typeof value of "object." The
jQuery.isPlainObject() method identifies whether the passed argument is a
plain object or not, as demonstrated below:
var a = [];
var d = document;
var o = {};
typeof a; // object
typeof d; // object
typeof o; // object
jQuery.isPlainObject( a ); // false
jQuery.isPlainObject( d ); // false
jQuery.isPlainObject( o ); // true
font-size

REFERENCE
http://api.jquery.com/Types/

Mais conteúdo relacionado

Mais procurados

Javascript built in String Functions
Javascript built in String FunctionsJavascript built in String Functions
Javascript built in String Functions
Avanitrambadiya
 
Java script introducation & basics
Java script introducation & basicsJava script introducation & basics
Java script introducation & basics
H K
 
Opa presentation at GamesJs
Opa presentation at GamesJsOpa presentation at GamesJs
Opa presentation at GamesJs
Henri Binsztok
 
Symfony2 and Doctrine2 Integration
Symfony2 and Doctrine2 IntegrationSymfony2 and Doctrine2 Integration
Symfony2 and Doctrine2 Integration
Jonathan Wage
 
11. session 11 functions and objects
11. session 11   functions and objects11. session 11   functions and objects
11. session 11 functions and objects
Phúc Đỗ
 
JavaScript: Variables and Functions
JavaScript: Variables and FunctionsJavaScript: Variables and Functions
JavaScript: Variables and Functions
Jussi Pohjolainen
 

Mais procurados (20)

Javascript built in String Functions
Javascript built in String FunctionsJavascript built in String Functions
Javascript built in String Functions
 
JavaScript 101 - Class 1
JavaScript 101 - Class 1JavaScript 101 - Class 1
JavaScript 101 - Class 1
 
Swift 함수 커링 사용하기
Swift 함수 커링 사용하기Swift 함수 커링 사용하기
Swift 함수 커링 사용하기
 
JavaScript - Chapter 10 - Strings and Arrays
 JavaScript - Chapter 10 - Strings and Arrays JavaScript - Chapter 10 - Strings and Arrays
JavaScript - Chapter 10 - Strings and Arrays
 
Java script arrays
Java script arraysJava script arrays
Java script arrays
 
Java script introducation & basics
Java script introducation & basicsJava script introducation & basics
Java script introducation & basics
 
Oop concepts in python
Oop concepts in pythonOop concepts in python
Oop concepts in python
 
Class 5 - PHP Strings
Class 5 - PHP StringsClass 5 - PHP Strings
Class 5 - PHP Strings
 
Opa presentation at GamesJs
Opa presentation at GamesJsOpa presentation at GamesJs
Opa presentation at GamesJs
 
Implementing a many-to-many Relationship with Slick
Implementing a many-to-many Relationship with SlickImplementing a many-to-many Relationship with Slick
Implementing a many-to-many Relationship with Slick
 
From OOP To FP Through A Practical Case
From OOP To FP Through A Practical CaseFrom OOP To FP Through A Practical Case
From OOP To FP Through A Practical Case
 
What are arrays in java script
What are arrays in java scriptWhat are arrays in java script
What are arrays in java script
 
Variables, expressions, standard types
 Variables, expressions, standard types  Variables, expressions, standard types
Variables, expressions, standard types
 
Symfony2 and Doctrine2 Integration
Symfony2 and Doctrine2 IntegrationSymfony2 and Doctrine2 Integration
Symfony2 and Doctrine2 Integration
 
Hardened JavaScript
Hardened JavaScriptHardened JavaScript
Hardened JavaScript
 
Quebec pdo
Quebec pdoQuebec pdo
Quebec pdo
 
PHP Functions & Arrays
PHP Functions & ArraysPHP Functions & Arrays
PHP Functions & Arrays
 
11. session 11 functions and objects
11. session 11   functions and objects11. session 11   functions and objects
11. session 11 functions and objects
 
How to write code you won't hate tomorrow
How to write code you won't hate tomorrowHow to write code you won't hate tomorrow
How to write code you won't hate tomorrow
 
JavaScript: Variables and Functions
JavaScript: Variables and FunctionsJavaScript: Variables and Functions
JavaScript: Variables and Functions
 

Semelhante a Js types

Stuff you didn't know about action script
Stuff you didn't know about action scriptStuff you didn't know about action script
Stuff you didn't know about action script
Christophe Herreman
 
Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
Varun C M
 
Java script
 Java script Java script
Java script
bosybosy
 
10. session 10 loops and arrays
10. session 10   loops and arrays10. session 10   loops and arrays
10. session 10 loops and arrays
Phúc Đỗ
 
ES6 General Introduction
ES6 General IntroductionES6 General Introduction
ES6 General Introduction
Thomas Johnston
 
Java script objects 1
Java script objects 1Java script objects 1
Java script objects 1
H K
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
tonyh1
 

Semelhante a Js types (20)

Stuff you didn't know about action script
Stuff you didn't know about action scriptStuff you didn't know about action script
Stuff you didn't know about action script
 
Ajax and JavaScript Bootcamp
Ajax and JavaScript BootcampAjax and JavaScript Bootcamp
Ajax and JavaScript Bootcamp
 
Javascript
JavascriptJavascript
Javascript
 
Java script
Java scriptJava script
Java script
 
Javascript variables and datatypes
Javascript variables and datatypesJavascript variables and datatypes
Javascript variables and datatypes
 
Introduction to Client-Side Javascript
Introduction to Client-Side JavascriptIntroduction to Client-Side Javascript
Introduction to Client-Side Javascript
 
Java script
 Java script Java script
Java script
 
jQuery introduction
jQuery introductionjQuery introduction
jQuery introduction
 
Java Script Introduction
Java Script IntroductionJava Script Introduction
Java Script Introduction
 
JQuery Presentation
JQuery PresentationJQuery Presentation
JQuery Presentation
 
10. session 10 loops and arrays
10. session 10   loops and arrays10. session 10   loops and arrays
10. session 10 loops and arrays
 
ES6 General Introduction
ES6 General IntroductionES6 General Introduction
ES6 General Introduction
 
Java Script ppt
Java Script pptJava Script ppt
Java Script ppt
 
JavaScript Workshop
JavaScript WorkshopJavaScript Workshop
JavaScript Workshop
 
"Javascript" por Tiago Rodrigues
"Javascript" por Tiago Rodrigues"Javascript" por Tiago Rodrigues
"Javascript" por Tiago Rodrigues
 
The JavaScript Programming Language
The JavaScript Programming LanguageThe JavaScript Programming Language
The JavaScript Programming Language
 
Java script objects 1
Java script objects 1Java script objects 1
Java script objects 1
 
JavaScript.pptx
JavaScript.pptxJavaScript.pptx
JavaScript.pptx
 
An introduction to javascript
An introduction to javascriptAn introduction to javascript
An introduction to javascript
 
Pragmatic Real-World Scala (short version)
Pragmatic Real-World Scala (short version)Pragmatic Real-World Scala (short version)
Pragmatic Real-World Scala (short version)
 

Mais de LearningTech (20)

vim
vimvim
vim
 
PostCss
PostCssPostCss
PostCss
 
ReactJs
ReactJsReactJs
ReactJs
 
Docker
DockerDocker
Docker
 
Semantic ui
Semantic uiSemantic ui
Semantic ui
 
node.js errors
node.js errorsnode.js errors
node.js errors
 
Process control nodejs
Process control nodejsProcess control nodejs
Process control nodejs
 
Expression tree
Expression treeExpression tree
Expression tree
 
SQL 效能調校
SQL 效能調校SQL 效能調校
SQL 效能調校
 
flexbox report
flexbox reportflexbox report
flexbox report
 
Vic weekly learning_20160504
Vic weekly learning_20160504Vic weekly learning_20160504
Vic weekly learning_20160504
 
Reflection &amp; activator
Reflection &amp; activatorReflection &amp; activator
Reflection &amp; activator
 
Peggy markdown
Peggy markdownPeggy markdown
Peggy markdown
 
Node child process
Node child processNode child process
Node child process
 
20160415ken.lee
20160415ken.lee20160415ken.lee
20160415ken.lee
 
Peggy elasticsearch應用
Peggy elasticsearch應用Peggy elasticsearch應用
Peggy elasticsearch應用
 
Expression tree
Expression treeExpression tree
Expression tree
 
Vic weekly learning_20160325
Vic weekly learning_20160325Vic weekly learning_20160325
Vic weekly learning_20160325
 
D3js learning tips
D3js learning tipsD3js learning tips
D3js learning tips
 
git command
git commandgit command
git command
 

Último

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Último (20)

Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
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...
 
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...
 
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...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
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
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
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
 

Js types

  • 2. 大綱  htmlString  Number  Object  Array  PlainObject
  • 3. font-size HTMLSTRING  A string is designated htmlString in jQuery documentation when it is used to represent one or more DOM elements, typically to be created and inserted in the document.  For explicit parsing of a string to HTML, the $.parseHTML() method is available as of jQuery 1.8  // Appends <b>hello</b>:  $( "<b>hello</b>" ).appendTo( "body" );  // Appends <b>hello</b>:  $( "<b>hello</b>bye" ).appendTo( "body" );  // Syntax error, unrecognized expression: bye<b>hello</b>  $( "bye<b>hello</b>" ).appendTo( "body" );  // Appends bye<b>hello</b>:  $( $.parseHTML( "bye<b>hello</b>" ) ).appendTo( "body" );  // Appends <b>hello</b>wait<b>bye</b>:  $( "<b>hello</b>wait<b>bye</b>" ).appendTo( "body" );  For explicit parsing of a string to HTML, use the $.parseHTML()
  • 4. font-size NUMBER The type of a number is "number". typeof 12 // "number" typeof 3.543 // "number“ if a number is zero, it defaults to false: !0 // true !!0 // false !1 // false !-1 // false Due to the implementation of numbers as double-precision values, the following result is not an error: 0.1 + 0.2 // 0.30000000000000004
  • 5. font-size NUMBER  Parsing Numbers  parseInt and parseFloat help parsing strings into numbers. Both do some implicit conversion if the base isn't specified:       parseInt( "123" ) = 123 // (implicit decimal) parseInt( "010" ) = 8 // (implicit octal) parseInt( "0xCAFE" ) = 51966 // (implicit hexadecimal) parseInt( "010", 10 ) = 10 // (explicit decimal) parseInt( "11", 2 ) = 3 // (explicit binary) parseFloat( "10.10" ) = 10.1
  • 6. font-size NUMBER  Numbers to Strings  When appending numbers to string, the result is always a string. The operator is the same, so be careful: If you want to add numbers and then append them to a string, put parentheses around them:     "" + 1 + 2; // "12" "" + ( 1 + 2 ); // "3" "" + 0.0000001; // "1e-7" parseInt( 0.0000001 ); // 1 (!) , 1e-7 parseInt() -> 1  Or you use the String class provided by javascript, which try to parse a value as string  String( 1 ) + String( 2 ); // "12"  String( 1 + 2 ); // "3"
  • 7. font-size NUMBER  NaN and Infinity  Parsing something that isn't a number results in NaN. isNaN helps to detect those cases:  parseInt( "hello", 10 ) // NaN  isNaN( parseInt("hello", 10) ) // true  Division by zero results in Infinity:  1 / 0 // Infinity  Both NaN and Infinity are of type "number":  typeof NaN // "number"  typeof Infinity // "number“
  • 8. font-size NUMBER  Note that NaN compares in a strange way:  NaN == NaN // false (!)  But:  Infinity == Infinity // true
  • 9. font-size OBJECT Everything in JavaScript is an object var x = {}; var y = { name: "Pete", age: 15 }; The type of an object is "object": typeof {} // "object“ Use Dot or Array Notation to write and read properties var obj = { name: "Pete", age: 15 }; for( key in obj ) { alert( "key is " + [ key ] + ", value is " + obj[ key ] ); } Note that for-in-loop can be spoiled by extending Object.prototype so take care when using other libraries.Use jQuery.each(obj, function( key, value ))
  • 10. font-size OBJECT An object, no matter if it has properties or not, never defaults to false: !{} // false !!{} // true
  • 11. font-size ARRAY Arrays in JavaScript are mutable lists with a few built-in methods. You can define arrays using the array literal: var x = []; var y = [ 1, 2, 3 ]; The type of an array is "object": typeof []; // "object" typeof [ 1, 2, 3 ]; // "object“ Reading and writing elements to an array uses the array-notation: x[ 0 ] = 1; y[ 2 ] // 3  The length property can also be used to add elements to the end of an array var x = []; x.push( 1 ); x[ x.length ] = 2; x[1000] = 1; // x.length = 1000
  • 12. font-size ARRAY jQuery provides a generic each function to iterate over element of arrays, as well as properties of objects: var x = [ 1, 2, 3 ]; jQuery.each( x, function( index, value ) { console.log( "index", index, "value", value ); }); The length property can also be used to add elements to the end of an array. That is equivalent to using the push-method: var x = [ 0, 3, 1, 2 ]; x.reverse() // x = [ 2, 1, 3, 0 ] x.join(" – ") // "2 - 1 - 3 - 0" x.pop() // pop 0 , x= [ 2, 1, 3 ] x.unshift( -1 ) // newlength 4 , x = [ -1, 2, 1, 3 ] x.shift() // remove -1 , x = [ 2, 1, 3 ] x.sort() // [ 1, 2, 3 ] x.splice( 1, 2 ) // remove 2,3 , x =[1 ] An array, no matter if it has elements or not, never defaults to false: ![] // false !![] // true
  • 13. font-size PLAINOBJECT The PlainObject type is a JavaScript object containing zero or more keyvalue pairs. The plain object is, in other words, an Object object. It is designated "plain" in jQuery documentation to distinguish it from other kinds of JavaScript objects: for example, null, user-defined arrays, and host objects such as document, all of which have a typeof value of "object." The jQuery.isPlainObject() method identifies whether the passed argument is a plain object or not, as demonstrated below: var a = []; var d = document; var o = {}; typeof a; // object typeof d; // object typeof o; // object jQuery.isPlainObject( a ); // false jQuery.isPlainObject( d ); // false jQuery.isPlainObject( o ); // true