Muutke küpsiste eelistusi

E-raamat: JavaScript: Syntax and Practices [Taylor & Francis e-raamat]

(Persistent Systems, Bangalore, India), (Graphic Era Univ., Dehradun)
  • Formaat: 280 pages, 11 Tables, black and white; 25 Line drawings, black and white; 4 Halftones, black and white; 29 Illustrations, black and white
  • Ilmumisaeg: 13-Dec-2021
  • Kirjastus: Chapman & Hall/CRC
  • ISBN-13: 9781003122364
  • Taylor & Francis e-raamat
  • Hind: 170,80 €*
  • * hind, mis tagab piiramatu üheaegsete kasutajate arvuga ligipääsu piiramatuks ajaks
  • Tavahind: 244,00 €
  • Säästad 30%
  • Formaat: 280 pages, 11 Tables, black and white; 25 Line drawings, black and white; 4 Halftones, black and white; 29 Illustrations, black and white
  • Ilmumisaeg: 13-Dec-2021
  • Kirjastus: Chapman & Hall/CRC
  • ISBN-13: 9781003122364
JavaScript is an easy-to-use, flexible, dynamic, prototype-based programming language predominantly used over the web. Although the initial focus of the language was to assist in the generation of dynamic web content, it soon found its way into numerous other applications. This book aims to cover the fundamentals of the language by providing a strong start for people who wish to start their journey to the JavaScript programming language. It provides the mandatory theoretical background, which is much needed for implementation of the exhaustive hands-on exercises and includes over 4000 lines of code for grasping a maximum understanding of the material.

FEATURES











A strong theoretical background and understanding of the fundamentals of the JavaScript language





Hands-on and demo exercises at the end of every chapter





Exercises, theory-based questions, MCQs and true/false questions for helping readers to evaluate their understanding from time to time





A dedicated chapter providing extended case studies for using the language

This book is targeted at undergraduate as well as postgraduate students who want to learn about front-end programming or who wish to learn a lightweight, easy-to-use programming language for working on their projects. For programmers having experience in other languages, it will serve as a quick summary to get a hold of a new language.
Preface xv
Acknowledgements xvii
Authors xix
1 Introduction
1(18)
1.1 Introduction to Web Development
1(2)
1.2 Client-Side and Server-Side JavaScript
3(1)
1.3 Origin, History and Evolution of JavaScript
4(2)
1.4 Features of JavaScript
6(2)
1.5 Advantages and Limitations
8(2)
1.6 Structure of Browsers
10(1)
1.7 Saying Hello World to JS
11(4)
1.7.1 Built-in Functions
12(1)
1.7.2 Gathering Software
13(1)
1.7.2.1 Examples of Framework, Library and Tools
14(1)
1.8 Placement of Code
15(2)
1.9 Exercise
17(2)
1.9.1 Theory
17(1)
1.9.2 True/False
17(1)
1.9.3 Multiple-Choice Questions
18(1)
2 Building the Basics
19(28)
2.1 Lexical Structure
19(1)
2.2 Character Set
19(3)
2.2.1 Whitespace and Comments
20(1)
2.2.2 Case Sensitivity
20(1)
2.2.3 Semicolons
20(1)
2.2.4 Literals
21(1)
2.2.5 Identifiers
21(1)
2.2.6 Keywords
21(1)
2.3 Variables
22(2)
2.3.1 Variable Declaration and Scope
22(2)
2.4 Data Types
24(5)
2.4.1 Primitive Data Types
25(2)
2.4.2 Nonprimitive Data Types
27(1)
2.4.3 Constants
27(1)
2.4.4 Type Casting
28(1)
2.5 Operators
29(5)
2.5.1 Arithmetic Operators
29(1)
2.5.2 Comparison Operators
29(2)
2.5.3 Bitwise Operators
31(1)
2.5.4 Logical Operators
31(1)
2.5.5 Assignment Operator
31(1)
2.5.6 Ternary Operator
32(1)
2.5.7 Comma Operator
33(1)
2.5.8 Typeof Operator
33(1)
2.5.9 Delete Operator
34(1)
2.5.10 Void Operator
34(1)
2.6 Control Flow Statements
34(5)
2.6.1 Decision Statements
34(1)
2.6.1.1 If Else
35(1)
2.6.1.2 Switch Case Statement
36(1)
2.6.2 Loops and Iterations
37(1)
2.6.2.1 For Loop
37(1)
2.6.2.2 While Loop
38(1)
2.6.2.3 Do-While Loop
38(1)
2.6.2.4 For-In Loop
39(1)
2.7 Exercise
39(2)
2.7.1 Theory
39(1)
2.7.2 True/False
40(1)
2.7.3 Multiple-Choice Questions
40(1)
2.8 Demo and Hands-On for Variables and Assignment Operator
41(2)
2.8.1 Objective
41(1)
2.8.2 Prerequisite
41(1)
2.8.3 Explore
42(1)
2.8.3.1 Code Snippet-1
42(1)
2.8.3.2 Code Snippet-2
42(1)
2.8.3.3 Code Snippet-3
43(1)
2.9 Demo and Hands-On for Control Flow Statements
43(4)
2.9.1 Objective
43(1)
2.9.2 Prerequisite
44(1)
2.9.3 Explore
44(1)
2.9.3.1 Code Snippet-1
44(1)
2.9.3.2 Code Snippet-2
45(2)
3 Objects
47(34)
3.1 Objects
48(2)
3.2 Properties of Objects
50(2)
3.2.1 Property Configuration Descriptors
50(2)
3.3 Creating Objects
52(2)
3.4 Objects as Record and Dictionary
54(1)
3.5 Operations on Objects
55(8)
3.5.1 Accessors and Mutators
55(2)
3.5.2 Useful Operations and Loops
57(3)
3.5.3 Object Methods
60(1)
3.5.4 Built-in Object Methods
61(2)
3.6 Prototypal Inheritance
63(2)
3.6.1 Prototype Chaining
64(1)
3.7 Classes
65(6)
3.7.1 Constructor, Properties and Methods
66(2)
3.7.2 Extending Classes
68(1)
3.7.3 Getters and Setters in Classes
69(1)
3.7.4 Static Members
70(1)
3.8 Garbage Collection
71(2)
3.9 Exercise
73(2)
3.9.1 Theory
73(1)
3.9.2 True/False
73(1)
3.9.3 Multiple-Choice Questions
74(1)
3.10 Demo and Hands-On for Objects
75(6)
3.10.1 Objective
75(1)
3.10.2 Prerequisite
75(1)
3.10.3 Explore
75(1)
3.10.3.1 Code Snippet-1
76(1)
3.10.3.2 Code Snippet-2
77(1)
3.10.3.3 Code Snippet-3
78(3)
4 Functions
81(18)
4.1 Functions in JavaScript
81(1)
4.2 Function Variable Scope
82(2)
4.3 Function Declaration
84(5)
4.3.1 Traditional Function Declaration
85(1)
4.3.2 Function Expressions
85(1)
4.3.3 Arrow Function Expressions
86(1)
4.3.3.1 Limitations of Arrow Functions
87(2)
4.4 Parameters in a Function
89(2)
4.4.1 Return Keyword in Functions
89(1)
4.4.2 Invoking a Function
89(1)
4.4.3 Recursion
90(1)
4.4.4 Closures
90(1)
4.5 Exercise
91(2)
4.5.1 Theory
91(1)
4.5.2 True/False
91(1)
4.5.3 Multiple-Choice Questions
92(1)
4.6 Demo and Hands-On for Functions
93(6)
4.6.1 Objective
93(1)
4.6.2 Prerequisite
93(1)
4.6.3 Explore
93(1)
4.6.3.1 Code Snippet-1
94(2)
4.6.3.2 Code Snippet-2
96(3)
5 Arrays
99(28)
5.1 Array
99(1)
5.2 Properties of Array
100(1)
5.3 Declaring an Array
100(2)
5.3.1 Array Literal
101(1)
5.3.2 Using the New Keyword and Array Constructor
101(1)
5.4 Accessing an Array
102(1)
5.5 Built-in Methods inside Array
103(13)
5.5.1 Accessor Methods
103(4)
5.5.2 Mutator Methods
107(4)
5.5.3 Iterator Methods
111(1)
5.5.3.1 Using Fundamental Loops
112(1)
5.5.3.2 Predefined Iterator Methods
112(4)
5.6 Nesting and Multidimensional Arrays
116(1)
5.7 Sorting
117(2)
5.8 Points to Ponder
119(1)
5.9 Exercise
120(2)
5.9.1 Theory
120(1)
5.9.2 True/False
120(1)
5.9.3 Multiple-Choice Questions
120(2)
5.10 Demo and Hands-On for Arrays
122(5)
5.10.1 Objective
122(1)
5.10.2 Prerequisite
122(1)
5.10.3 Explore
122(1)
5.10.3.1 Code Snippet-1
122(1)
5.10.3.2 Code Snippet-2
123(2)
5.10.3.3 Code Snippet-3
125(2)
6 Browser Object Model
127(18)
6.1 Browser Object Model
127(2)
6.2 Window Object
129(5)
6.2.1 Properties of Window Object
131(1)
6.2.2 Methods of Window Object
132(2)
6.3 History Object
134(2)
6.3.1 Properties of History Object
135(1)
6.3.2 Methods of History Object
135(1)
6.4 Navigator Object
136(2)
6.4.1 Properties and Methods of Navigator Object
137(1)
6.5 Location Object
138(1)
6.5.1 Properties of Location Object
138(1)
6.5.2 Methods of Location Object
139(1)
6.6 Screen Object
139(1)
6.6.1 Properties of Screen Object
139(1)
6.7 Document Object
140(1)
6.8 Exercise
140(2)
6.8.1 Theory
140(1)
6.8.2 True/False
140(1)
6.8.3 Multiple-Choice Questions
141(1)
6.9 Demo and Hands-On for BOM
142(3)
6.9.1 Objective
142(1)
6.9.2 Prerequisites
142(1)
6.9.3 Explore
142(1)
6.9.3.1 Code Snippet-1
142(1)
6.9.3.2 Code Snippet-2
143(2)
7 Document Object Model
145(34)
7.1 Document Object Model (DOM)
145(3)
7.2 Relationship between BOM, DOM and JavaScript
148(3)
7.3 Understanding DOM Tree and Nodes
151(4)
7.3.1 Properties of Node Object
153(1)
7.3.2 Method of Node Object
154(1)
7.4 Document Object
155(2)
7.4.1 Properties of Document Object
155(1)
7.4.2 Methods for Document Object
156(1)
7.5 Elements in DOM
157(2)
7.5.1 Properties of Element Object
157(1)
7.5.2 Methods for Element Object
158(1)
7.6 Accessing Elements in the DOM
159(3)
7.7 Event Handling Using DOM
162(2)
7.8 Exercise
164(1)
7.8.1 Theory
164(1)
7.8.2 True/False
164(1)
7.8.3 Multiple-Choice Questions
164(1)
7.9 Demo and Hands-On DOM
165(9)
7.9.1 Objective
165(1)
7.9.2 Prerequisite
165(1)
7.9.3 Explore
166(1)
7.9.3.1 Code Snippet-1
166(1)
7.9.3.2 Code Snippet-2
167(2)
7.9.3.3 Code Snippet-3
169(1)
7.9.3.4 Code Snippet-4
170(4)
7.10 Demo and Hands-On for Event Delegation
174(5)
7.10.1 Objective
174(1)
7.10.2 Prerequisite
174(1)
7.10.3 Explore
175(1)
7.10.3.1 Code Snippet-1
175(2)
7.10.3.2 Code Snippet-2
177(2)
8 Standard Built-in Objects
179(32)
8.1 Built-in Objects
179(22)
8.1.1 Fundamental Objects
180(1)
8.1.1.1 Object Prototype
180(1)
8.1.1.2 Function Object
181(1)
8.1.1.3 Boolean Object
181(2)
8.1.1.4 Symbol Object
183(1)
8.1.2 Error Objects
184(1)
8.1.3 Number and Dates
184(1)
8.1.3.1 Number Object
184(2)
8.1.3.2 Date Object
186(2)
8.1.3.3 Math Object
188(2)
8.1.4 Text or String Processing
190(1)
8.1.4.1 String Object
190(3)
8.1.4.2 RegExp Object
193(2)
8.1.5 Keyed Collections
195(1)
8.1.5.1 Map Object
195(1)
8.1.5.2 Set Object
196(1)
8.1.6 Indexed Collections
197(1)
8.1.6.1 Array Object
197(2)
8.1.7 Structured Data
199(1)
8.1.8 Value Properties
199(1)
8.1.9 Function Properties
200(1)
8.2 Exercise
201(2)
8.2.1 Theory
201(1)
8.2.2 True/False
202(1)
8.2.3 Multiple-Choice Questions
202(1)
8.3 Demo and Hands-On for Loops
203(4)
8.3.1 Objective
203(1)
8.3.2 Prerequisite
203(1)
8.3.3 Explore
203(1)
8.3.3.1 Code Snippet-1
203(1)
8.3.3.2 Code Snippet-2
204(1)
8.3.3.3 Code Snippet-3
205(2)
8.4 Demo and Hands-On for Hoisting
207(4)
8.4.1 Objective
207(1)
8.4.2 Prerequisite
207(1)
8.4.3 Explore
207(1)
8.4.3.1 Code Snippet-1
208(1)
8.4.3.2 Code Snippet-2
209(2)
9 Validation, Error Handling and Cookies
211(18)
9.1 Validation
211(4)
9.1.1 Server- and Client-Side Validation
212(1)
9.1.2 Using Built-in Form Validation
212(2)
9.1.3 Using JavaScript for Validation
214(1)
9.2 Error Handling
215(4)
9.2.1 Error Object
216(1)
9.2.2 Try-Catch Block
217(1)
9.2.3 Finally Block
218(1)
9.2.4 Throw Statement
219(1)
9.3 Cookies
219(1)
9.4 Strict Mode
220(2)
9.5 Best Practices
222(2)
9.6 Exercise
224(2)
9.6.1 Theory
224(1)
9.6.2 True/False
225(1)
9.6.3 Multiple-Choice Questions
225(1)
9.7 Demo and Hands-On for Form Validation and Cookies
226(3)
9.7.1 Objective
226(1)
9.7.2 Prerequisite
226(1)
9.7.3 Explore
226(1)
9.7.3.1 Code Snippet-1
226(3)
10 Miscellaneous Case Studies
229(16)
10.1 Case Study-1: Introduction to Fetch API
229(2)
10.1.1 Objective
229(1)
10.1.2 Prerequisite
229(1)
10.1.3 Explore
230(1)
10.1.3.1 Code Snippet-1
230(1)
10.2 Case Study-2: Integrating MongoDB in Cloud
231(6)
10.2.1 Objective
231(1)
10.2.2 Prerequisite
231(1)
10.2.2.1 MongoDB Cloud Connection
231(1)
10.2.2.2 Docker Container for Node.js
232(1)
10.2.3 Agenda
233(1)
10.2.4 Explore
233(1)
10.2.4.1 Front-End Script for Invoking Our Custom APIs
233(1)
10.2.4.2 Code Walkthrough
234(1)
10.2.4.3 Creating Node.js Backend
234(3)
10.3 Case Study-3: Visualizing Graphs with JavaScript
237(2)
10.3.1 Objective
237(1)
10.3.2 Prerequisite
237(1)
10.3.3 Agenda
237(1)
10.3.4 Explore
237(1)
10.3.5 Front-End Script for Invoking Our Custom APIs
237(2)
10.4 Case Study-4: Integrating Firebase Auth
239(6)
10.4.1 Objective
239(1)
10.4.2 Background
239(1)
10.4.3 Prerequisite
239(1)
10.4.4 Agenda
240(1)
10.4.5 Explore
240(1)
10.4.5.1 Creating a Login Page
240(1)
10.4.5.2 Code Walkthrough
241(1)
10.4.5.3 Creating Home Page
242(1)
10.4.5.4 Code Walkthrough
243(2)
References 245(8)
Index 253
Dr Ravi Tomar is currently working as Associate Professor in the School of Computer Science at the University of Petroleum & Energy Studies, Dehradun, India. He is an experienced academician with a demonstrated history of working in the higher education industry. Skilled in Programming, Computer Networking, Stream processing, Python, Oracle Database, C++, Core Java, J2EE, RPA and CorDApp. His research interests include Wireless Sensor Networks, Image Processing, Data Mining and Warehousing, Computer Networks, big data technologies and VANET. He has authored 60+ papers in different research areas, filled four Indian patent, edited 5 books, and have authored 4 books. He has delivered Training to corporates nationally and internationally on Confluent Apache Kafka, Stream Processing, RPA, CordaApp, J2EE and IoT to clients like KeyBank, Accenture, Union Bank of Philippines, Ernst and Young and Deloitte. Dr Tomar is officially recognized as Instructor for Confluent and CordApp. He has conducted various international conferences in India, France and Nepal. He has been awarded a young researcher in Computer Science and Engineering by RedInno, India in 2018, Academic Excellence and Research Excellence Award by UPES in 2021 and conferred by Research Excellence Award 2021 by Honble Chief Minister of Uttarakhand State, India.

Ms Sarishma Dangi is currently working in the capacity of Assistant Professor in the Computer Science and Engineering department at Graphic Era University, Dehradun, India. She is a Google Cloud Certified Professional Cloud Architect specialized in the area of virtualization and cloud computing. She is a bright young enthusiast driven towards innovative research work and dedicated to imparting quality education to the higher education industry. She has authored many research papers in recognized journals and has authored a book on "Mobile Cloud Computing: Principles and Paradigms". Her research interests include blockchain, virtualization, vehicular ad-hoc networks and live memory forensics. She is currently pursuing her PhD with full rigour.