Share E-Book
Scan to open this page

Scan with your phone to open this page

Author: Marijn Haverbeke

Rating No ratings yet

Completely revised and updated, this best-selling introduction to programming in JavaScript focuses on writing real applications. Eloquent JavaScript dives into the JavaScript language to show programmers how to write elegant, effective JavaScript code. Like any good programming book, Eloquent JavaScript begins with fundamentals — variables, control structures, functions, and data structures — then moves on to complex topics like object-oriented programming and regular expressions. This third edition introduces new features covering the 2017 version of JavaScript, such as class notation, arrow functions, iterators, async functions, template strings, and block scope. Author Marijn Haverbeke keeps the friendly tone and easy-to-follow explanations that made the original a hit, and he adds new exercises for readers to test their skills. Eloquent JavaScript will have readers fluent in the language of the web in no time, eloquently.

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

AI guide
【One-Line Pitch】 A patient, example-driven tour of JavaScript that treats programming as a craft rather than a syntax checklist—ideal for motivated beginners and self-taught developers who want to understand *why* code works, not just copy it. 【Book Arc】 - **Opening (~0%–10%)**: Sets up what programming is and why language choice matters, then grounds you in values, types, operators, and program structure (bindings, control flow, loops). - **Early (~10%–30%)**: Builds the core toolkit—functions, scope, closures, recursion, data structures, higher-order array methods, objects, prototypes, classes, and error handling—before introducing regular expressions and modules. - **Middle (~30%–50%)**: Shifts toward real-world concerns: asynchronous programming (callbacks, promises, async functions, the event loop), then the browser environment—HTML, the DOM, styling, and HTTP/forms. - **Late (~50%–60%)**: Consolidates everything through larger projects, including a robot simulation, a small programming language, a platform game, and a pixel-art editor. - **Ending (~60%+ per excerpts)**: Extends beyond the browser into Node.js (modules, NPM, file system, HTTP, streams) and a capstone skill-sharing website project, with exercise hints closing the book. 【Key Takeaways】 - **Fundamentals are treated as first-class material, not a warm-up** (Opening): values, types, and control flow get careful treatment because everything later depends on them. - **Functions are the book's spine** (Early): closures, recursion, and higher-order functions are explained through concrete examples rather than abstract theory. - **Objects and prototypes are demystified** (Early): encapsulation, methods, classes, inheritance, and iterators are unpacked so JavaScript's object model stops feeling arbitrary. - **Errors and testing are part of writing code, not an afterthought** (Early): strict mode, debugging, exceptions, and assertions are woven into the learning path. - **Asynchrony gets a full, honest treatment** (Middle): callbacks, promises, async functions, generators, and the event loop are covered with attention to real failure modes. - **The browser is taught as a platform, not just a runtime** (Middle): DOM manipulation, styling, HTTP, forms, and client-side storage connect language features to actual web pages. - **Projects are the payoff** (Late): a robot, a toy language, a game, and a pixel editor each force you to integrate many concepts at once. - **The book reaches past the browser** (Ending): Node.js, NPM, streams, and a server-backed project show JavaScript as a general-purpose tool. 【Reading Tips】 - **Do the exercises.** The book is built around them; skipping them turns a hands-on course into passive reading. - **Deep-read the functions, objects, and async chapters.** These are the conceptual hinges—later projects assume fluency here. - **Skim the project chapters on a first pass**, then return and build them yourself; they're integration tests for everything before. - **Keep a scratch console open.** Most ideas here are best confirmed by typing a few lines and watching what happens. - **Don't fear the browser chapters even if you're backend-minded**—they clarify async and event-driven thinking that transfers everywhere. 【Coverage Limits】 This guide is based on stratified excerpts (front matter, table of contents, and chapter headings); it does not cover the book's prose style, specific exercise content, or the bonus print-only chapter.
Page 3
included, printed by No Starch Press at https://www.amazon.com/Eloquent-JavaScript- 2nd-Ed-Introduction/dp/1593275846. i Contents Introduction 1 On programmi...
View in text
Page 6
g arrays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 Transforming with map . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Summ...
View in text
Page 8
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212 Cheating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213 Exercises...
View in text
Page 10
. . . . 313 Appreciating HTTP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314 Security and HTTPS . . . . . . . . . . . . . . . . . . . . . . ....
View in text
Page 13
ly is no application. That is where programming may come in. Programming is the act of con- structing a program—a set of precise instructions telling a compu...
View in text
Page 15
ing simple programs required much cleverness and discipline. Complex ones were nearly inconceivable. Of course, manually entering these arcane patterns of bi...
View in text
Page 19
sers are not the only platforms on which JavaScript is used. Some databases, such as MongoDB and CouchDB, use JavaScript as their scripting and query languag...
View in text
Page 20
hapters in this part. After that, Chapter 20 describes Node.js, and Chapter 21 builds a small website using that tool. Typographic conventions In this book,...
View in text
Tags
AI categories
JavaScriptProgramming LanguageWeb Technology
ISBN: 1593279507
Publisher: No Starch Press
Publish Year: 2018
Language: English
Pages: 447
File Format: PDF
File Size: 11.0 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…