lgli/JavaScript The Definitive Guide Master the World's Most-Used Programming Language 7th Edition.pdf
JavaScript : the definitive guide : master the world's most-used programming language 🔍
David Flanagan
O'Reilly Media, Incorporated, 7th Edition, Jun 02, 2020
英语 [en] · PDF · 6.7MB · 2020 · 📘 非小说类图书 · 🚀/lgli/lgrs/zlib · Save
描述
JavaScript is the programming language of the web and is used by more software developers today than any other programming language. For nearly 25 years this best seller has been the go-to guide for JavaScript programmers. The seventh edition is fully updated to cover the 2020 version of JavaScript, and new chapters cover classes, modules, iterators, generators, Promises, async/await, and metaprogramming. You’ll find illuminating and engaging example code throughout.
This book is for programmers who want to learn JavaScript and for web developers who want to take their understanding and mastery to the next level. It begins by explaining the JavaScript language itself, in detail, from the bottom up. It then builds on that foundation to cover the web platform and Node.js.
Topics include:
Types, values, variables, expressions, operators, statements, objects, and arrays Functions, classes, modules, iterators, generators, Promises, and async/await JavaScript’s standard library: data structures, regular expressions, JSON, i18n, etc. The web platform: documents, components, graphics, networking, storage, and threads Node.js: buffers, files, streams, threads, child processes, web clients, and web servers Tools and language extensions that professional JavaScript developers rely on
This book is for programmers who want to learn JavaScript and for web developers who want to take their understanding and mastery to the next level. It begins by explaining the JavaScript language itself, in detail, from the bottom up. It then builds on that foundation to cover the web platform and Node.js.
Topics include:
Types, values, variables, expressions, operators, statements, objects, and arrays Functions, classes, modules, iterators, generators, Promises, and async/await JavaScript’s standard library: data structures, regular expressions, JSON, i18n, etc. The web platform: documents, components, graphics, networking, storage, and threads Node.js: buffers, files, streams, threads, child processes, web clients, and web servers Tools and language extensions that professional JavaScript developers rely on
备用文件名
lgrsnf/JavaScript The Definitive Guide Master the World's Most-Used Programming Language 7th Edition.pdf
备用文件名
zlib/Computers/Programming/David Flanagan/JavaScript: The Definitive Guide: Master the World's Most-Used Programming Language_5527104.pdf
备选标题
JavaScript. Полное руководство: справочник по самому популярному языку программирования
备选作者
Дэвид Флэнаган; перевод с английского и редакция Ю. Н. Артеменко
备选作者
Flanagan, David
备选作者
Флэнаган, Дэвид
备用出版商
б. и.; Диалектика
备用版本
7-е изд., Москва, Санкт-Петербург, Russia, 2021
备用版本
United States, United States of America
备用版本
Seventh edition, Sebastopol, CA, 2020
备用版本
Seventh edition, Beijing [China, 2020
备用版本
O'Reilly Media, [S.l.], 2020
元数据中的注释
Converted
元数据中的注释
lg2525740
元数据中的注释
Source title: JavaScript: The Definitive Guide: Master the World's Most-Used Programming Language
元数据中的注释
Предм. указ.: с. 714-720
Фактическая дата выхода в свет - 2020
Пер.: Flanagan, David JavaScript: the definitive guide Beijing [etc.] : O'Reilly, 2020 978-1-491-95202-3
Фактическая дата выхода в свет - 2020
Пер.: Flanagan, David JavaScript: the definitive guide Beijing [etc.] : O'Reilly, 2020 978-1-491-95202-3
元数据中的注释
РГБ
元数据中的注释
Russian State Library [rgb] MARC:
=001 010529132
=005 20210111133016.0
=008 201222s2021\\\\ru\\\\\\\\\\\\|||\|\rus|d
=017 \\ $a КН-П-20-084889 $b RuMoRKP
=020 \\ $a 978-5-907203-79-2 $c 400 экз.
=040 \\ $a RuMoRKP $b rus $e rcr $d RuMoRGB
=041 1\ $a rus $h eng
=084 \\ $a З973.233.02-018.19JavaScript.я22 $2 rubbk
=100 1\ $a Флэнаган, Дэвид
=245 00 $a JavaScript. Полное руководство : $b справочник по самому популярному языку программирования $c Дэвид Флэнаган ; перевод с английского и редакция Ю. Н. Артеменко
=250 \\ $a 7-е изд.
=260 \\ $a Москва $b [б. и.] ; $a Санкт-Петербург $b Диалектика $c 2021
=300 \\ $a 720 с. $b ил. $c 25 см
=500 \\ $a Предм. указ.: с. 714-720
=500 \\ $a Фактическая дата выхода в свет - 2020
=534 \\ $p Пер.: $a Flanagan, David $t JavaScript: the definitive guide $c Beijing [etc.] : O'Reilly, 2020 $z 978-1-491-95202-3
=650 \7 $a Техника. Технические науки -- Энергетика. Радиоэлектроника -- Радиоэлектроника -- Вычислительная техника -- Электронные вычислительные машины (компьютеры) -- Цифровые электронные вычислительные машины. Программирование -- Специализированные компьютеры и системы. Отдельные информационные технологии -- Автоматическая обработка информации -- Информационные системы и сети -- Программирование -- Языки программирования -- JavaScript -- Справочник $2 rubbk
=852 \\ $a РГБ $b FB $j 2 20-70/30 $x 90
=852 7\ $a РГБ $b CZ2 $h З973.2-018/Ф73 $x 83
=001 010529132
=005 20210111133016.0
=008 201222s2021\\\\ru\\\\\\\\\\\\|||\|\rus|d
=017 \\ $a КН-П-20-084889 $b RuMoRKP
=020 \\ $a 978-5-907203-79-2 $c 400 экз.
=040 \\ $a RuMoRKP $b rus $e rcr $d RuMoRGB
=041 1\ $a rus $h eng
=084 \\ $a З973.233.02-018.19JavaScript.я22 $2 rubbk
=100 1\ $a Флэнаган, Дэвид
=245 00 $a JavaScript. Полное руководство : $b справочник по самому популярному языку программирования $c Дэвид Флэнаган ; перевод с английского и редакция Ю. Н. Артеменко
=250 \\ $a 7-е изд.
=260 \\ $a Москва $b [б. и.] ; $a Санкт-Петербург $b Диалектика $c 2021
=300 \\ $a 720 с. $b ил. $c 25 см
=500 \\ $a Предм. указ.: с. 714-720
=500 \\ $a Фактическая дата выхода в свет - 2020
=534 \\ $p Пер.: $a Flanagan, David $t JavaScript: the definitive guide $c Beijing [etc.] : O'Reilly, 2020 $z 978-1-491-95202-3
=650 \7 $a Техника. Технические науки -- Энергетика. Радиоэлектроника -- Радиоэлектроника -- Вычислительная техника -- Электронные вычислительные машины (компьютеры) -- Цифровые электронные вычислительные машины. Программирование -- Специализированные компьютеры и системы. Отдельные информационные технологии -- Автоматическая обработка информации -- Информационные системы и сети -- Программирование -- Языки программирования -- JavaScript -- Справочник $2 rubbk
=852 \\ $a РГБ $b FB $j 2 20-70/30 $x 90
=852 7\ $a РГБ $b CZ2 $h З973.2-018/Ф73 $x 83
备用描述
Preface
Conventions Used in This Book
Example Code
O’Reilly Online Learning
How to Contact Us
Acknowledgments
Introduction to JavaScript
1.1 Exploring JavaScript
1.2 Hello World
1.3 A Tour of JavaScript
1.4 Example: Character Frequency Histograms
1.5 Summary
Lexical Structure
2.1 The Text of a JavaScript Program
2.2 Comments
2.3 Literals
2.4 Identifiers and Reserved Words
2.4.1 Reserved Words
2.5 Unicode
2.5.1 Unicode Escape Sequences
2.5.2 Unicode Normalization
2.6 Optional Semicolons
2.7 Summary
Types, Values, and Variables
3.1 Overview and Definitions
3.2 Numbers
3.2.1 Integer Literals
3.2.2 Floating-Point Literals
3.2.3 Arithmetic in JavaScript
3.2.4 Binary Floating-Point and Rounding Errors
3.2.5 Arbitrary Precision Integers with BigInt
3.2.6 Dates and Times
3.3 Text
3.3.1 String Literals
3.3.2 Escape Sequences in String Literals
3.3.3 Working with Strings
3.3.4 Template Literals
3.3.5 Pattern Matching
3.4 Boolean Values
3.5 null and undefined
3.6 Symbols
3.7 The Global Object
3.8 Immutable Primitive Values and Mutable Object References
3.9 Type Conversions
3.9.1 Conversions and Equality
3.9.2 Explicit Conversions
3.9.3 Object to Primitive Conversions
3.10 Variable Declaration and Assignment
3.10.1 Declarations with let and const
3.10.2 Variable Declarations with var
3.10.3 Destructuring Assignment
3.11 Summary
Expressions and Operators
4.1 Primary Expressions
4.2 Object and Array Initializers
4.3 Function Definition Expressions
4.4 Property Access Expressions
4.4.1 Conditional Property Access
4.5 Invocation Expressions
4.5.1 Conditional Invocation
4.6 Object Creation Expressions
4.7 Operator Overview
4.7.1 Number of Operands
4.7.2 Operand and Result Type
4.7.3 Operator Side Effects
4.7.4 Operator Precedence
4.7.5 Operator Associativity
4.7.6 Order of Evaluation
4.8 Arithmetic Expressions
4.8.1 The + Operator
4.8.2 Unary Arithmetic Operators
4.8.3 Bitwise Operators
4.9 Relational Expressions
4.9.1 Equality and Inequality Operators
4.9.2 Comparison Operators
4.9.3 The in Operator
4.9.4 The instanceof Operator
4.10 Logical Expressions
4.10.1 Logical AND (&&)
4.10.2 Logical OR (||)
4.10.3 Logical NOT (!)
4.11 Assignment Expressions
4.11.1 Assignment with Operation
4.12 Evaluation Expressions
4.12.1 eval()
4.12.2 Global eval()
4.12.3 Strict eval()
4.13 Miscellaneous Operators
4.13.1 The Conditional Operator (?:)
4.13.2 First-Defined (??)
4.13.3 The typeof Operator
4.13.4 The delete Operator
4.13.5 The await Operator
4.13.6 The void Operator
4.13.7 The comma Operator (,)
4.14 Summary
Statements
5.1 Expression Statements
5.2 Compound and Empty Statements
5.3 Conditionals
5.3.1 if
5.3.2 else if
5.3.3 switch
5.4 Loops
5.4.1 while
5.4.2 do/while
5.4.3 for
5.4.4 for/of
5.4.5 for/in
5.5 Jumps
5.5.1 Labeled Statements
5.5.2 break
5.5.3 continue
5.5.4 return
5.5.5 yield
5.5.6 throw
5.5.7 try/catch/finally
5.6 Miscellaneous Statements
5.6.1 with
5.6.2 debugger
5.6.3 “use strict”
5.7 Declarations
5.7.1 const, let, and var
5.7.2 function
5.7.3 class
5.7.4 import and export
5.8 Summary of JavaScript Statements
Objects
6.1 Introduction to Objects
6.2 Creating Objects
6.2.1 Object Literals
6.2.2 Creating Objects with new
6.2.3 Prototypes
6.2.4 Object.create()
6.3 Querying and Setting Properties
6.3.1 Objects As Associative Arrays
6.3.2 Inheritance
6.3.3 Property Access Errors
6.4 Deleting Properties
6.5 Testing Properties
6.6 Enumerating Properties
6.6.1 Property Enumeration Order
6.7 Extending Objects
6.8 Serializing Objects
6.9 Object Methods
6.9.1 The toString() Method
6.9.2 The toLocaleString() Method
6.9.3 The valueOf() Method
6.9.4 The toJSON() Method
6.10 Extended Object Literal Syntax
6.10.1 Shorthand Properties
6.10.2 Computed Property Names
6.10.3 Symbols as Property Names
6.10.4 Spread Operator
6.10.5 Shorthand Methods
6.10.6 Property Getters and Setters
6.11 Summary
Arrays
7.1 Creating Arrays
7.1.1 Array Literals
7.1.2 The Spread Operator
7.1.3 The Array() Constructor
7.1.4 Array.of()
7.1.5 Array.from()
7.2 Reading and Writing Array Elements
7.3 Sparse Arrays
7.4 Array Length
7.5 Adding and Deleting Array Elements
7.6 Iterating Arrays
7.7 Multidimensional Arrays
7.8 Array Methods
7.8.1 Array Iterator Methods
7.8.2 Flattening arrays with flat() and flatMap()
7.8.3 Adding arrays with concat()
7.8.4 Stacks and Queues with push(), pop(), shift(), and unshift()
7.8.5 Subarrays with slice(), splice(), fill(), and copyWithin()
7.8.6 Array Searching and Sorting Methods
7.8.7 Array to String Conversions
7.8.8 Static Array Functions
7.9 Array-Like Objects
7.10 Strings as Arrays
7.11 Summary
Functions
8.1 Defining Functions
8.1.1 Function Declarations
8.1.2 Function Expressions
8.1.3 Arrow Functions
8.1.4 Nested Functions
8.2 Invoking Functions
8.2.1 Function Invocation
8.2.2 Method Invocation
8.2.3 Constructor Invocation
8.2.4 Indirect Invocation
8.2.5 Implicit Function Invocation
8.3 Function Arguments and Parameters
8.3.1 Optional Parameters and Defaults
8.3.2 Rest Parameters and Variable-Length Argument Lists
8.3.3 The Arguments Object
8.3.4 The Spread Operator for Function Calls
8.3.5 Destructuring Function Arguments into Parameters
8.3.6 Argument Types
8.4 Functions as Values
8.4.1 Defining Your Own Function Properties
8.5 Functions as Namespaces
8.6 Closures
8.7 Function Properties, Methods, and Constructor
8.7.1 The length Property
8.7.2 The name Property
8.7.3 The prototype Property
8.7.4 The call() and apply() Methods
8.7.5 The bind() Method
8.7.6 The toString() Method
8.7.7 The Function() Constructor
8.8 Functional Programming
8.8.1 Processing Arrays with Functions
8.8.2 Higher-Order Functions
8.8.3 Partial Application of Functions
8.8.4 Memoization
8.9 Summary
Classes
9.1 Classes and Prototypes
9.2 Classes and Constructors
9.2.1 Constructors, Class Identity, and instanceof
9.2.2 The constructor Property
9.3 Classes with the class Keyword
9.3.1 Static Methods
9.3.2 Getters, Setters, and other Method Forms
9.3.3 Public, Private, and Static Fields
9.3.4 Example: A Complex Number Class
9.4 Adding Methods to Existing Classes
9.5 Subclasses
9.5.1 Subclasses and Prototypes
9.5.2 Subclasses with extends and super
9.5.3 Delegation Instead of Inheritance
9.5.4 Class Hierarchies and Abstract Classes
9.6 Summary
Modules
10.1 Modules with Classes, Objects, and Closures
10.1.1 Automating Closure-Based Modularity
10.2 Modules in Node
10.2.1 Node Exports
10.2.2 Node Imports
10.2.3 Node-Style Modules on the Web
10.3 Modules in ES6
10.3.1 ES6 Exports
10.3.2 ES6 Imports
10.3.3 Imports and Exports with Renaming
10.3.4 Re-Exports
10.3.5 JavaScript Modules on the Web
10.3.6 Dynamic Imports with import()
10.3.7 import.meta.url
10.4 Summary
The JavaScript Standard Library
11.1 Sets and Maps
11.1.1 The Set Class
11.1.2 The Map Class
11.1.3 WeakMap and WeakSet
11.2 Typed Arrays and Binary Data
11.2.1 Typed Array Types
11.2.2 Creating Typed Arrays
11.2.3 Using Typed Arrays
11.2.4 Typed Array Methods and Properties
11.2.5 DataView and Endianness
11.3 Pattern Matching with Regular Expressions
11.3.1 Defining Regular Expressions
11.3.2 String Methods for Pattern Matching
11.3.3 The RegExp Class
11.4 Dates and Times
11.4.1 Timestamps
11.4.2 Date Arithmetic
11.4.3 Formatting and Parsing Date Strings
11.5 Error Classes
11.6 JSON Serialization and Parsing
11.6.1 JSON Customizations
11.7 The Internationalization API
11.7.1 Formatting Numbers
11.7.2 Formatting Dates and Times
11.7.3 Comparing Strings
11.8 The Console API
11.8.1 Formatted Output with Console
11.9 URL APIs
11.9.1 Legacy URL Functions
11.10 Timers
11.11 Summary
Iterators and Generators
12.1 How Iterators Work
12.2 Implementing Iterable Objects
12.2.1 “Closing” an Iterator: The Return Method
12.3 Generators
12.3.1 Generator Examples
12.3.2 yield* and Recursive Generators
12.4 Advanced Generator Features
12.4.1 The Return Value of a Generator Function
12.4.2 The Value of a yield Expression
12.4.3 The return() and throw() Methods of a Generator
12.4.4 A Final Note About Generators
12.5 Summary
Asynchronous JavaScript
13.1 Asynchronous Programming with Callbacks
13.1.1 Timers
13.1.2 Events
13.1.3 Network Events
13.1.4 Callbacks and Events in Node
13.2 Promises
13.2.1 Using Promises
13.2.2 Chaining Promises
13.2.3 Resolving Promises
13.2.4 More on Promises and Errors
13.2.5 Promises in Parallel
13.2.6 Making Promises
13.2.7 Promises in Sequence
13.3 async and await
13.3.1 await Expressions
13.3.2 async Functions
13.3.3 Awaiting Multiple Promises
13.3.4 Implementation Details
13.4 Asynchronous Iteration
13.4.1 The for/await Loop
13.4.2 Asynchronous Iterators
13.4.3 Asynchronous Generators
13.4.4 Implementing Asynchronous Iterators
13.5 Summary
Metaprogramming
14.1 Property Attributes
14.2 Object Extensibility
14.3 The prototype Attribute
14.4 Well-Known Symbols
14.4.1 Symbol.iterator and Symbol.asyncIterator
14.4.2 Symbol.hasInstance
14.4.3 Symbol.toStringTag
14.4.4 Symbol.species
14.4.5 Symbol.isConcatSpreadable
14.4.6 Pattern-Matching Symbols
14.4.7 Symbol.toPrimitive
14.4.8 Symbol.unscopables
14.5 Template Tags
14.6 The Reflect API
14.7 Proxy Objects
14.7.1 Proxy Invariants
14.8 Summary
JavaScript in Web Browsers
15.1 Web Programming Basics
15.1.1 JavaScript in HTML Tags
15.1.2 The Document Object Model
15.1.3 The Global Object in Web Browsers
15.1.4 Scripts Share a Namespace
15.1.5 Execution of JavaScript Programs
15.1.6 Program Input and Output
15.1.7 Program Errors
15.1.8 The Web Security Model
15.2 Events
15.2.1 Event Categories
15.2.2 Registering Event Handlers
15.2.3 Event Handler Invocation
15.2.4 Event Propagation
15.2.5 Event Cancellation
15.2.6 Dispatching Custom Events
15.3 Scripting Documents
15.3.1 Selecting Document Elements
15.3.2 Document Structure and Traversal
15.3.3 Attributes
15.3.4 Element Content
15.3.5 Creating, Inserting, and Deleting Nodes
15.3.6 Example: Generating a Table of Contents
15.4 Scripting CSS
15.4.1 CSS Classes
15.4.2 Inline Styles
15.4.3 Computed Styles
15.4.4 Scripting Stylesheets
15.4.5 CSS Animations and Events
15.5 Document Geometry and Scrolling
15.5.1 Document Coordinates and Viewport Coordinates
15.5.2 Querying the Geometry of an Element
15.5.3 Determining the Element at a Point
15.5.4 Scrolling
15.5.5 Viewport Size, Content Size, and Scroll Position
15.6 Web Components
15.6.1 Using Web Components
15.6.2 HTML Templates
15.6.3 Custom Elements
15.6.4 Shadow DOM
15.6.5 Example: a Web Component
15.7 SVG: Scalable Vector Graphics
15.7.1 SVG in HTML
15.7.2 Scripting SVG
15.7.3 Creating SVG Images with JavaScript
15.8 Graphics in a
15.8.1 Paths and Polygons
15.8.2 Canvas Dimensions and Coordinates
15.8.3 Graphics Attributes
15.8.4 Canvas Drawing Operations
15.8.5 Coordinate System Transforms
15.8.6 Clipping
15.8.7 Pixel Manipulation
15.9 Audio APIs
15.9.1 The Audio() Constructor
15.9.2 The WebAudio API
15.10 Location, Navigation, and History
15.10.1 Loading New Documents
15.10.2 Browsing History
15.10.3 History Management with hashchange Events
15.10.4 History Management with pushState()
15.11 Networking
15.11.1 fetch()
15.11.2 Server-Sent Events
15.11.3 WebSockets
15.12 Storage
15.12.1 localStorage and sessionStorage
15.12.2 Cookies
15.12.3 IndexedDB
15.13 Worker Threads and Messaging
15.13.1 Worker Objects
15.13.2 The Global Object in Workers
15.13.3 Importing Code into a Worker
15.13.4 Worker Execution Model
15.13.5 postMessage(), MessagePorts, and MessageChannels
15.13.6 Cross-Origin Messaging with postMessage()
15.14 Example: The Mandelbrot Set
15.15 Summary and Suggestions for Further Reading
15.15.1 HTML and CSS
15.15.2 Performance
15.15.3 Security
15.15.4 WebAssembly
15.15.5 More Document and Window Features
15.15.6 Events
15.15.7 Progressive Web Apps and Service Workers
15.15.8 Mobile Device APIs
15.15.9 Binary APIs
15.15.10 Media APIs
15.15.11 Cryptography and Related APIs
Server-Side JavaScript with Node
16.1 Node Programming Basics
16.1.1 Console Output
16.1.2 Command-Line Arguments and Environment Variables
16.1.3 Program Life Cycle
16.1.4 Node Modules
16.1.5 The Node Package Manager
16.2 Node Is Asynchronous by Default
16.3 Buffers
16.4 Events and EventEmitter
16.5 Streams
16.5.1 Pipes
16.5.2 Asynchronous Iteration
16.5.3 Writing to Streams and Handling Backpressure
16.5.4 Reading Streams with Events
16.6 Process, CPU, and Operating System Details
16.7 Working with Files
16.7.1 Paths, File Descriptors, and FileHandles
16.7.2 Reading Files
16.7.3 Writing Files
16.7.4 File Operations
16.7.5 File Metadata
16.7.6 Working with Directories
16.8 HTTP Clients and Servers
16.9 Non-HTTP Network Servers and Clients
16.10 Working with Child Processes
16.10.1 execSync() and execFileSync()
16.10.2 exec() and execFile()
16.10.3 spawn()
16.10.4 fork()
16.11 Worker Threads
16.11.1 Creating Workers and Passing Messages
16.11.2 The Worker Execution Environment
16.11.3 Communication Channels and MessagePorts
16.11.4 Transferring MessagePorts and Typed Arrays
16.11.5 Sharing Typed Arrays Between Threads
16.12 Summary
JavaScript Tools and Extensions
17.1 Linting with ESLint
17.2 JavaScript Formatting with Prettier
17.3 Unit Testing with Jest
17.4 Package Management with npm
17.5 Code Bundling
17.6 Transpilation with Babel
17.7 JSX: Markup Expressions in JavaScript
17.8 Type Checking with Flow
17.8.1 Installing and Running Flow
17.8.2 Using Type Annotations
17.8.3 Class Types
17.8.4 Object Types
17.8.5 Type Aliases
17.8.6 Array Types
17.8.7 Other Parameterized Types
17.8.8 Read-Only Types
17.8.9 Function Types
17.8.10 Union Types
17.8.11 Enumerated Types and Discriminated Unions
17.9 Summary
Index
Conventions Used in This Book
Example Code
O’Reilly Online Learning
How to Contact Us
Acknowledgments
Introduction to JavaScript
1.1 Exploring JavaScript
1.2 Hello World
1.3 A Tour of JavaScript
1.4 Example: Character Frequency Histograms
1.5 Summary
Lexical Structure
2.1 The Text of a JavaScript Program
2.2 Comments
2.3 Literals
2.4 Identifiers and Reserved Words
2.4.1 Reserved Words
2.5 Unicode
2.5.1 Unicode Escape Sequences
2.5.2 Unicode Normalization
2.6 Optional Semicolons
2.7 Summary
Types, Values, and Variables
3.1 Overview and Definitions
3.2 Numbers
3.2.1 Integer Literals
3.2.2 Floating-Point Literals
3.2.3 Arithmetic in JavaScript
3.2.4 Binary Floating-Point and Rounding Errors
3.2.5 Arbitrary Precision Integers with BigInt
3.2.6 Dates and Times
3.3 Text
3.3.1 String Literals
3.3.2 Escape Sequences in String Literals
3.3.3 Working with Strings
3.3.4 Template Literals
3.3.5 Pattern Matching
3.4 Boolean Values
3.5 null and undefined
3.6 Symbols
3.7 The Global Object
3.8 Immutable Primitive Values and Mutable Object References
3.9 Type Conversions
3.9.1 Conversions and Equality
3.9.2 Explicit Conversions
3.9.3 Object to Primitive Conversions
3.10 Variable Declaration and Assignment
3.10.1 Declarations with let and const
3.10.2 Variable Declarations with var
3.10.3 Destructuring Assignment
3.11 Summary
Expressions and Operators
4.1 Primary Expressions
4.2 Object and Array Initializers
4.3 Function Definition Expressions
4.4 Property Access Expressions
4.4.1 Conditional Property Access
4.5 Invocation Expressions
4.5.1 Conditional Invocation
4.6 Object Creation Expressions
4.7 Operator Overview
4.7.1 Number of Operands
4.7.2 Operand and Result Type
4.7.3 Operator Side Effects
4.7.4 Operator Precedence
4.7.5 Operator Associativity
4.7.6 Order of Evaluation
4.8 Arithmetic Expressions
4.8.1 The + Operator
4.8.2 Unary Arithmetic Operators
4.8.3 Bitwise Operators
4.9 Relational Expressions
4.9.1 Equality and Inequality Operators
4.9.2 Comparison Operators
4.9.3 The in Operator
4.9.4 The instanceof Operator
4.10 Logical Expressions
4.10.1 Logical AND (&&)
4.10.2 Logical OR (||)
4.10.3 Logical NOT (!)
4.11 Assignment Expressions
4.11.1 Assignment with Operation
4.12 Evaluation Expressions
4.12.1 eval()
4.12.2 Global eval()
4.12.3 Strict eval()
4.13 Miscellaneous Operators
4.13.1 The Conditional Operator (?:)
4.13.2 First-Defined (??)
4.13.3 The typeof Operator
4.13.4 The delete Operator
4.13.5 The await Operator
4.13.6 The void Operator
4.13.7 The comma Operator (,)
4.14 Summary
Statements
5.1 Expression Statements
5.2 Compound and Empty Statements
5.3 Conditionals
5.3.1 if
5.3.2 else if
5.3.3 switch
5.4 Loops
5.4.1 while
5.4.2 do/while
5.4.3 for
5.4.4 for/of
5.4.5 for/in
5.5 Jumps
5.5.1 Labeled Statements
5.5.2 break
5.5.3 continue
5.5.4 return
5.5.5 yield
5.5.6 throw
5.5.7 try/catch/finally
5.6 Miscellaneous Statements
5.6.1 with
5.6.2 debugger
5.6.3 “use strict”
5.7 Declarations
5.7.1 const, let, and var
5.7.2 function
5.7.3 class
5.7.4 import and export
5.8 Summary of JavaScript Statements
Objects
6.1 Introduction to Objects
6.2 Creating Objects
6.2.1 Object Literals
6.2.2 Creating Objects with new
6.2.3 Prototypes
6.2.4 Object.create()
6.3 Querying and Setting Properties
6.3.1 Objects As Associative Arrays
6.3.2 Inheritance
6.3.3 Property Access Errors
6.4 Deleting Properties
6.5 Testing Properties
6.6 Enumerating Properties
6.6.1 Property Enumeration Order
6.7 Extending Objects
6.8 Serializing Objects
6.9 Object Methods
6.9.1 The toString() Method
6.9.2 The toLocaleString() Method
6.9.3 The valueOf() Method
6.9.4 The toJSON() Method
6.10 Extended Object Literal Syntax
6.10.1 Shorthand Properties
6.10.2 Computed Property Names
6.10.3 Symbols as Property Names
6.10.4 Spread Operator
6.10.5 Shorthand Methods
6.10.6 Property Getters and Setters
6.11 Summary
Arrays
7.1 Creating Arrays
7.1.1 Array Literals
7.1.2 The Spread Operator
7.1.3 The Array() Constructor
7.1.4 Array.of()
7.1.5 Array.from()
7.2 Reading and Writing Array Elements
7.3 Sparse Arrays
7.4 Array Length
7.5 Adding and Deleting Array Elements
7.6 Iterating Arrays
7.7 Multidimensional Arrays
7.8 Array Methods
7.8.1 Array Iterator Methods
7.8.2 Flattening arrays with flat() and flatMap()
7.8.3 Adding arrays with concat()
7.8.4 Stacks and Queues with push(), pop(), shift(), and unshift()
7.8.5 Subarrays with slice(), splice(), fill(), and copyWithin()
7.8.6 Array Searching and Sorting Methods
7.8.7 Array to String Conversions
7.8.8 Static Array Functions
7.9 Array-Like Objects
7.10 Strings as Arrays
7.11 Summary
Functions
8.1 Defining Functions
8.1.1 Function Declarations
8.1.2 Function Expressions
8.1.3 Arrow Functions
8.1.4 Nested Functions
8.2 Invoking Functions
8.2.1 Function Invocation
8.2.2 Method Invocation
8.2.3 Constructor Invocation
8.2.4 Indirect Invocation
8.2.5 Implicit Function Invocation
8.3 Function Arguments and Parameters
8.3.1 Optional Parameters and Defaults
8.3.2 Rest Parameters and Variable-Length Argument Lists
8.3.3 The Arguments Object
8.3.4 The Spread Operator for Function Calls
8.3.5 Destructuring Function Arguments into Parameters
8.3.6 Argument Types
8.4 Functions as Values
8.4.1 Defining Your Own Function Properties
8.5 Functions as Namespaces
8.6 Closures
8.7 Function Properties, Methods, and Constructor
8.7.1 The length Property
8.7.2 The name Property
8.7.3 The prototype Property
8.7.4 The call() and apply() Methods
8.7.5 The bind() Method
8.7.6 The toString() Method
8.7.7 The Function() Constructor
8.8 Functional Programming
8.8.1 Processing Arrays with Functions
8.8.2 Higher-Order Functions
8.8.3 Partial Application of Functions
8.8.4 Memoization
8.9 Summary
Classes
9.1 Classes and Prototypes
9.2 Classes and Constructors
9.2.1 Constructors, Class Identity, and instanceof
9.2.2 The constructor Property
9.3 Classes with the class Keyword
9.3.1 Static Methods
9.3.2 Getters, Setters, and other Method Forms
9.3.3 Public, Private, and Static Fields
9.3.4 Example: A Complex Number Class
9.4 Adding Methods to Existing Classes
9.5 Subclasses
9.5.1 Subclasses and Prototypes
9.5.2 Subclasses with extends and super
9.5.3 Delegation Instead of Inheritance
9.5.4 Class Hierarchies and Abstract Classes
9.6 Summary
Modules
10.1 Modules with Classes, Objects, and Closures
10.1.1 Automating Closure-Based Modularity
10.2 Modules in Node
10.2.1 Node Exports
10.2.2 Node Imports
10.2.3 Node-Style Modules on the Web
10.3 Modules in ES6
10.3.1 ES6 Exports
10.3.2 ES6 Imports
10.3.3 Imports and Exports with Renaming
10.3.4 Re-Exports
10.3.5 JavaScript Modules on the Web
10.3.6 Dynamic Imports with import()
10.3.7 import.meta.url
10.4 Summary
The JavaScript Standard Library
11.1 Sets and Maps
11.1.1 The Set Class
11.1.2 The Map Class
11.1.3 WeakMap and WeakSet
11.2 Typed Arrays and Binary Data
11.2.1 Typed Array Types
11.2.2 Creating Typed Arrays
11.2.3 Using Typed Arrays
11.2.4 Typed Array Methods and Properties
11.2.5 DataView and Endianness
11.3 Pattern Matching with Regular Expressions
11.3.1 Defining Regular Expressions
11.3.2 String Methods for Pattern Matching
11.3.3 The RegExp Class
11.4 Dates and Times
11.4.1 Timestamps
11.4.2 Date Arithmetic
11.4.3 Formatting and Parsing Date Strings
11.5 Error Classes
11.6 JSON Serialization and Parsing
11.6.1 JSON Customizations
11.7 The Internationalization API
11.7.1 Formatting Numbers
11.7.2 Formatting Dates and Times
11.7.3 Comparing Strings
11.8 The Console API
11.8.1 Formatted Output with Console
11.9 URL APIs
11.9.1 Legacy URL Functions
11.10 Timers
11.11 Summary
Iterators and Generators
12.1 How Iterators Work
12.2 Implementing Iterable Objects
12.2.1 “Closing” an Iterator: The Return Method
12.3 Generators
12.3.1 Generator Examples
12.3.2 yield* and Recursive Generators
12.4 Advanced Generator Features
12.4.1 The Return Value of a Generator Function
12.4.2 The Value of a yield Expression
12.4.3 The return() and throw() Methods of a Generator
12.4.4 A Final Note About Generators
12.5 Summary
Asynchronous JavaScript
13.1 Asynchronous Programming with Callbacks
13.1.1 Timers
13.1.2 Events
13.1.3 Network Events
13.1.4 Callbacks and Events in Node
13.2 Promises
13.2.1 Using Promises
13.2.2 Chaining Promises
13.2.3 Resolving Promises
13.2.4 More on Promises and Errors
13.2.5 Promises in Parallel
13.2.6 Making Promises
13.2.7 Promises in Sequence
13.3 async and await
13.3.1 await Expressions
13.3.2 async Functions
13.3.3 Awaiting Multiple Promises
13.3.4 Implementation Details
13.4 Asynchronous Iteration
13.4.1 The for/await Loop
13.4.2 Asynchronous Iterators
13.4.3 Asynchronous Generators
13.4.4 Implementing Asynchronous Iterators
13.5 Summary
Metaprogramming
14.1 Property Attributes
14.2 Object Extensibility
14.3 The prototype Attribute
14.4 Well-Known Symbols
14.4.1 Symbol.iterator and Symbol.asyncIterator
14.4.2 Symbol.hasInstance
14.4.3 Symbol.toStringTag
14.4.4 Symbol.species
14.4.5 Symbol.isConcatSpreadable
14.4.6 Pattern-Matching Symbols
14.4.7 Symbol.toPrimitive
14.4.8 Symbol.unscopables
14.5 Template Tags
14.6 The Reflect API
14.7 Proxy Objects
14.7.1 Proxy Invariants
14.8 Summary
JavaScript in Web Browsers
15.1 Web Programming Basics
15.1.1 JavaScript in HTML Tags
15.1.2 The Document Object Model
15.1.3 The Global Object in Web Browsers
15.1.4 Scripts Share a Namespace
15.1.5 Execution of JavaScript Programs
15.1.6 Program Input and Output
15.1.7 Program Errors
15.1.8 The Web Security Model
15.2 Events
15.2.1 Event Categories
15.2.2 Registering Event Handlers
15.2.3 Event Handler Invocation
15.2.4 Event Propagation
15.2.5 Event Cancellation
15.2.6 Dispatching Custom Events
15.3 Scripting Documents
15.3.1 Selecting Document Elements
15.3.2 Document Structure and Traversal
15.3.3 Attributes
15.3.4 Element Content
15.3.5 Creating, Inserting, and Deleting Nodes
15.3.6 Example: Generating a Table of Contents
15.4 Scripting CSS
15.4.1 CSS Classes
15.4.2 Inline Styles
15.4.3 Computed Styles
15.4.4 Scripting Stylesheets
15.4.5 CSS Animations and Events
15.5 Document Geometry and Scrolling
15.5.1 Document Coordinates and Viewport Coordinates
15.5.2 Querying the Geometry of an Element
15.5.3 Determining the Element at a Point
15.5.4 Scrolling
15.5.5 Viewport Size, Content Size, and Scroll Position
15.6 Web Components
15.6.1 Using Web Components
15.6.2 HTML Templates
15.6.3 Custom Elements
15.6.4 Shadow DOM
15.6.5 Example: a Web Component
15.7 SVG: Scalable Vector Graphics
15.7.1 SVG in HTML
15.7.2 Scripting SVG
15.7.3 Creating SVG Images with JavaScript
15.8 Graphics in a
15.8.1 Paths and Polygons
15.8.2 Canvas Dimensions and Coordinates
15.8.3 Graphics Attributes
15.8.4 Canvas Drawing Operations
15.8.5 Coordinate System Transforms
15.8.6 Clipping
15.8.7 Pixel Manipulation
15.9 Audio APIs
15.9.1 The Audio() Constructor
15.9.2 The WebAudio API
15.10 Location, Navigation, and History
15.10.1 Loading New Documents
15.10.2 Browsing History
15.10.3 History Management with hashchange Events
15.10.4 History Management with pushState()
15.11 Networking
15.11.1 fetch()
15.11.2 Server-Sent Events
15.11.3 WebSockets
15.12 Storage
15.12.1 localStorage and sessionStorage
15.12.2 Cookies
15.12.3 IndexedDB
15.13 Worker Threads and Messaging
15.13.1 Worker Objects
15.13.2 The Global Object in Workers
15.13.3 Importing Code into a Worker
15.13.4 Worker Execution Model
15.13.5 postMessage(), MessagePorts, and MessageChannels
15.13.6 Cross-Origin Messaging with postMessage()
15.14 Example: The Mandelbrot Set
15.15 Summary and Suggestions for Further Reading
15.15.1 HTML and CSS
15.15.2 Performance
15.15.3 Security
15.15.4 WebAssembly
15.15.5 More Document and Window Features
15.15.6 Events
15.15.7 Progressive Web Apps and Service Workers
15.15.8 Mobile Device APIs
15.15.9 Binary APIs
15.15.10 Media APIs
15.15.11 Cryptography and Related APIs
Server-Side JavaScript with Node
16.1 Node Programming Basics
16.1.1 Console Output
16.1.2 Command-Line Arguments and Environment Variables
16.1.3 Program Life Cycle
16.1.4 Node Modules
16.1.5 The Node Package Manager
16.2 Node Is Asynchronous by Default
16.3 Buffers
16.4 Events and EventEmitter
16.5 Streams
16.5.1 Pipes
16.5.2 Asynchronous Iteration
16.5.3 Writing to Streams and Handling Backpressure
16.5.4 Reading Streams with Events
16.6 Process, CPU, and Operating System Details
16.7 Working with Files
16.7.1 Paths, File Descriptors, and FileHandles
16.7.2 Reading Files
16.7.3 Writing Files
16.7.4 File Operations
16.7.5 File Metadata
16.7.6 Working with Directories
16.8 HTTP Clients and Servers
16.9 Non-HTTP Network Servers and Clients
16.10 Working with Child Processes
16.10.1 execSync() and execFileSync()
16.10.2 exec() and execFile()
16.10.3 spawn()
16.10.4 fork()
16.11 Worker Threads
16.11.1 Creating Workers and Passing Messages
16.11.2 The Worker Execution Environment
16.11.3 Communication Channels and MessagePorts
16.11.4 Transferring MessagePorts and Typed Arrays
16.11.5 Sharing Typed Arrays Between Threads
16.12 Summary
JavaScript Tools and Extensions
17.1 Linting with ESLint
17.2 JavaScript Formatting with Prettier
17.3 Unit Testing with Jest
17.4 Package Management with npm
17.5 Code Bundling
17.6 Transpilation with Babel
17.7 JSX: Markup Expressions in JavaScript
17.8 Type Checking with Flow
17.8.1 Installing and Running Flow
17.8.2 Using Type Annotations
17.8.3 Class Types
17.8.4 Object Types
17.8.5 Type Aliases
17.8.6 Array Types
17.8.7 Other Parameterized Types
17.8.8 Read-Only Types
17.8.9 Function Types
17.8.10 Union Types
17.8.11 Enumerated Types and Discriminated Unions
17.9 Summary
Index
备用描述
JavaScript is a powerful, object-based scripting language; JavaScript programs can be embedded directly into HTML web pages. When combined with the Document Object Model (DOM) defined by a web browser, JavaScript allows you to create Dynamic HTML (DHTML) content and interactive client-side web applications. JavaScript syntax is based on the popular programming languages C, C++, and Java, which makes it familiar and easy to learn for experienced programmers. At the same time, JavaScript is an interpreted scripting language, providing a flexible, forgiving environment in which new programmers can learn.
*JavaScript: The Definitive Guide* provides a thorough description of the core JavaScript language and both the legacy and standard DOMs implemented in web browsers. The book includes sophisticated examples that show you how to handle common tasks such as validating form data, working with cookies, and creating portable DHTML animations. The book also contains detailed reference sections that cover the core JavaScript API, the legacy client-side API, and the W3C standard DOM API, documenting every JavaScript object, method, property, constructor, constant, function, and event handler in those APIs.
This fourth edition of the bestselling JavaScript book has been carefully updated to cover JavaScript 1.5 (ECMAScript Version 3). The book also provides complete coverage of the W3C DOM standard (Level 1 and Level 2), while retaining material on the legacy Level 0 DOM for backward compatibility.
*JavaScript: The Definitive Guide* is a complete programmer's guide and reference manual for JavaScript. It is particularly useful for developers working with the latest standards-compliant web browsers, such as Internet Explorer 6, Netscape 6, and Mozilla. HTML authors can learn how to use JavaScript to build dynamic web pages. Experienced programmers can quickly find the information they need to start writing sophisticated JavaScript programs. This book is an indispensable reference for all JavaScript programmers, regardless of experience level.
----------
*Description from the Fourth Edition (2007, O'Reilly Media)*
Printing History
August 1996
Beta Edition.
January 1997
Second Edition.
June 1998
Third Edition.
January 2002
Fourth Edition.
*JavaScript: The Definitive Guide* provides a thorough description of the core JavaScript language and both the legacy and standard DOMs implemented in web browsers. The book includes sophisticated examples that show you how to handle common tasks such as validating form data, working with cookies, and creating portable DHTML animations. The book also contains detailed reference sections that cover the core JavaScript API, the legacy client-side API, and the W3C standard DOM API, documenting every JavaScript object, method, property, constructor, constant, function, and event handler in those APIs.
This fourth edition of the bestselling JavaScript book has been carefully updated to cover JavaScript 1.5 (ECMAScript Version 3). The book also provides complete coverage of the W3C DOM standard (Level 1 and Level 2), while retaining material on the legacy Level 0 DOM for backward compatibility.
*JavaScript: The Definitive Guide* is a complete programmer's guide and reference manual for JavaScript. It is particularly useful for developers working with the latest standards-compliant web browsers, such as Internet Explorer 6, Netscape 6, and Mozilla. HTML authors can learn how to use JavaScript to build dynamic web pages. Experienced programmers can quickly find the information they need to start writing sophisticated JavaScript programs. This book is an indispensable reference for all JavaScript programmers, regardless of experience level.
----------
*Description from the Fourth Edition (2007, O'Reilly Media)*
Printing History
August 1996
Beta Edition.
January 1997
Second Edition.
June 1998
Third Edition.
January 2002
Fourth Edition.
备用描述
From the cover. JavaScript is the programming language of the web and is used by more software developers today than any other programming language. For nearly 25 years this best seller has been the go-to guide for JavaScript programmers, and this new edition has been fully updated to cover the 2020 version of JavaScript. You'll find engaging and illuminating example code throughout and new chapters covering classes, modules, iterators, generators, Promises, and async/await. This book is for programmers who want to learn JavaScript and web developers ready to take their understanding and mastery of the language to the next level. Topics include: types, variables, operators, statements, objects, and arrays; functions, classes, modules, iterators, generators, Promises, and async/await; JavaScript's standard library: data structures, regular expressions, JSON, internationalization, and URLs; the web platform: documents, components, graphics, networking, storage, and threads; Node.js: buffers, files, streams, threads, child processes, web clients, and web servers; tools and language extensions that professional JavaScript developers rely on
备用描述
JavaScript is the programming language of the web and is used by more software developers today than any other programming language. For nearly 25 years this best seller has been the go-to guide for JavaScript programmers, and this new edition has been fully updated to cover the 2020 version of JavaScript. You'll find engaging and illuminating example code throughout and new chapters covering classes, modules, iterators, generators, Promises, and async/await. This book is for programmers who want to learn JavaScript and web developers ready to take their understanding and mastery of the language to the next level. -- Provided by publisher
备用描述
For Web Developers And Other Programmers Interested In Using Javascript, This Bestselling Book Provides The Most Comprehensive Javascript Reference Section On The Market. The Seventh Edition Represents A Significant Update, With New Material For Ecmascript 2017 (es8), And New Chapters On Language-specific Features. Javascript: The Definitive Guide Is Ideal For Experienced Programmers Who Want To Learn The Programming Language Of The Web, And For Current Javascript Programmers Who Want To Master It.
备用描述
For web developers and other programmers interested in using JavaScript, this bestselling book provides the most comprehensive JavaScript material on the market. The seventh edition represents a significant update, with new information for ECMAScript 2020, and new chapters on language-specific features.JavaScript: The Definitive Guide is ideal for experienced programmers who want to learn the programming language of the web, and for current JavaScript programmers who want to master it.
开源日期
2020-05-22
❌ 此文件可能有问题,已从源库中隐藏。 有时这是应版权所有者的要求,有时是因为有更好的选择, 但有时是因为文件本身有问题。 下载可能仍然没问题,但我们建议先搜索替代文件。 更多细节:
- 在 Libgen.rs 的非虚构文学板块中不可见 ("no")
- 此文件可能有更好的版本,位于 md5:aa16cfcab9f4b980b01675ec7ea75820
如果您仍想下载此文件,请确保仅使用受信任的最新软件打开它。
🚀 快速下载
成为会员以支持书籍、论文等的长期保存。为了感谢您对我们的支持,您将获得高速下载权益。❤️
🐢 低速下载
由可信的合作方提供。 更多信息请参见常见问题解答。 (可能需要验证浏览器——无限次下载!)
- 低速服务器(合作方提供) #1 (稍快但需要排队)
- 低速服务器(合作方提供) #2 (稍快但需要排队)
- 低速服务器(合作方提供) #3 (稍快但需要排队)
- 低速服务器(合作方提供) #4 (稍快但需要排队)
- 低速服务器(合作方提供) #5 (无需排队,但可能非常慢)
- 低速服务器(合作方提供) #6 (无需排队,但可能非常慢)
- 低速服务器(合作方提供) #7 (无需排队,但可能非常慢)
- 低速服务器(合作方提供) #8 (无需排队,但可能非常慢)
- 下载后: 在我们的查看器中打开
外部下载
-
对于大文件,我们建议使用下载管理器以防止中断。
推荐的下载管理器:Motrix -
您将需要一个电子书或 PDF 阅读器来打开文件,具体取决于文件格式。
推荐的电子书阅读器:Anna的档案在线查看器、ReadEra和Calibre -
使用在线工具进行格式转换。
推荐的转换工具:CloudConvert和PrintFriendly -
您可以将 PDF 和 EPUB 文件发送到您的 Kindle 或 Kobo 电子阅读器。
推荐的工具:亚马逊的“发送到 Kindle”和djazz 的“发送到 Kobo/Kindle” -
支持作者和图书馆
✍️ 如果您喜欢这个并且能够负担得起,请考虑购买原版,或直接支持作者。
📚 如果您当地的图书馆有这本书,请考虑在那里免费借阅。
下面的文字仅以英文继续。
总下载量:
“文件的MD5”是根据文件内容计算出的哈希值,并且基于该内容具有相当的唯一性。我们这里索引的所有影子图书馆都主要使用MD5来标识文件。
一个文件可能会出现在多个影子图书馆中。有关我们编译的各种数据集的信息,请参见数据集页面。
有关此文件的详细信息,请查看其JSON 文件。 Live/debug JSON version. Live/debug page.