Learning Javascript : a hands-on guide to the fundamentals of modern Javascript / Tim Wright.
Material type:

Item type | Current library | Home library | Collection | Shelving location | Call number | Copy number | Status | Date due | Barcode |
---|---|---|---|---|---|---|---|---|---|
![]() |
LRC - Main | National University - Manila | Computer Science | General Circulation | GC QA 76.73.J38 .W75 2013 (Browse shelf (Opens below)) | c.1 | Available | NULIB000006744 |
Includes index.
Chapter 1: Progressive Enhancement 3Defining Progressive Enhancement 3 History 4Purpose 5Accessibility 5Reusability 5Progressive Enhancement Versus GracefulDegradation 6Structure Layer 6Adding More Meaning with HTML5 8Presentation Layer 9Inline CSS 10Linking Up Your Stylesheet 10Behavior Layer 12Inline JavaScript 12Embedded JavaScript 13External and Unobtrusive JavaScript 15Benefits of Progressive Enhancement 16Performance 17Building for the Future 17The Touch Interface 18Final Words on Progressive Enhancement 19Summary 20Exercises 20Chapter 2: JavaScript in the Browser 21A People's History of JavaScript 21Origins 22Progressive Enhancement 23The Behavior Layer 24Moving Past Today 24Browser Interactions with JavaScript 25HTTP Requests 26JavaScript and Rendering Engines 29What JavaScript Can Do 30Modifying HTML 31Communicating with the Server 31Storing Data 31How You Should Use JavaScript 32Improving User Experience 32Using JavaScript Responsibly 32Creating Fallbacks 34Tools to Help You Use JavaScript 36Tools Built into the Language 36Tools Built into the Browser 37Summary 38Exercises 38Chapter 3: JavaScript Terminology 39Basics 39Document Object Model (DOM) 39Parents 40Children 40Siblings 41Variables 41Strings 43Comments 43Operators 44Use Strict 45Storage 45Cache 45Arrays 45Cookies 46JavaScript Object Notation (JSON) 46Objects 47Creating Interaction 47Loops 48Conditionals 48switch Statement 49Functions 50Anonymous Functions 51Callback Functions 52Methods 53Events 54Ajax 54Summary 55Exercises 55Chapter 4: Accessing the DOM 57What Is the DOM? 57The DOM Tree 58Element Nodes 59Text Nodes 60Attribute Nodes 62Working with the Element Node 62Targeting by ID 63Targeting by Tag Name 64Targeting by Class 67Using CSS Selectors in JavaScript to Target Nodes 68Working with the Attribute Node 70Getting an Attribute 71Setting an Attribute 72Removing an Attribute 73Working with the Text Node and Changing Content 73Moving Around the DOM 74Accessing First and Last Child 76Dynamically Adding and Removing Nodes from theDOM 77Adding Elements to the DOM 77Removing Elements from the DOM 78Summary 79Exercises 79Chapter 5: Storing Data in JavaScript 81Variables 81Strings 82Numbers 83Boolean 84Performance in Variables 84Arrays 85Basic Array 85Associative Array 87Multidimensional Array 87Pushing Data into an Array 89Working with Array Methods 89join 90slice 90shift and unshift 91pop 92concat 92sort 93Objects 93Performance in Objects 94JSON 95Benefits of Using JSON 96Using an API 96Web Storage in HTML5 97localStorage and sessionStorage 97setItem 97getItem 98removeItem 98Storing Chunks of Data with JSON 99Using Web Storage Responsibly 100Summary 101Exercises 101Chapter 6: Variables, Functions, and Loops 103Defining Variables 103Grouping Variables 104Reserved Terms 104Functions 105Basic Functions 106Anonymous Functions 107Scope 108Calling a Function with a Function 109Returning Data 110A Function as a Method 112Loops 113for Loop 114Conditionals 116if Statement 116if/else Statement 117switch Statement 118if versus switch 119Putting It All Together 120Summary 121Exercises 122Chapter 7: Interacting with the User Through Events 123Attaching an Event 124Event Handlers 124Event Listeners 125Binding Events 128Unbinding Events 129Mouse and Keyboard Events 130click 132focus and blur 134Accessibility 135change 135mouseover and mouseout (hovering) 136submit 137Preventing Default Behavior 139keydown, keypress, and keyup 139Putting It All Together 140Touch and Orientation Events 143touchstart and touchend 144touchmove 145orientationchange 145Support for Touch Events 146Putting It All Together 147Summary 148Exercises 148Chapter 8: Communicating with the Server ThroughAjax 149Ajax History 150Server Communication 151The XMLHttpRequest 152Creating an Ajax Call 154Sending a Request to the Server 155Receiving Data Back from the Server 158Making Repeat Ajax Calls 163Ajax Data Formats 164XML 165HTML 166JSON 167Ajax Accessibility 168Live Regions and ARIA 169Common Ajax Mistakes 170Providing Feedback 170Putting It All Together 172Where Is Ajax Going? 177Summary 177Exercises 178Chapter 9: Code Organization 179General Coding Style Rules 180Scope 181Failing Quickly 183User Experience 185Code Design 185Files and Directories 186In-document Script 187Variable Declarations 188Variable and Function Naming 189Comments 190Indentation 192Whitespace 193Statement Spacing 194Line Breaks 195Math and Operators 196Using eval() 197Taking Style Guides Too Far 199Code Structure 200Functions 200Anonymous Functions 201Functions as Variables 202Functions as Methods 202JavaScript Development Patterns 204Summary 208Exercises 209Chapter 10: Making JavaScript Easier with Libraries 211JavaScript Library Basics 212The Library Learning Process 213Syntax 214Focusing on the Goal 214Creating Shortcuts 215Fixing Browser Issues 216Popular Libraries 216jQuery Basics 221document.ready 222Selectors 223Traveling Through the DOM 225Adding Style Information 226Binding Events 227Animation 227jQuery Nonbasics 228Using Ajax in jQuery 228Looping Through Data in jQuery 230Chaining Functions 232Extending Libraries Through Plug-ins 233Building a Plug-in 234The Good of Libraries 236Popularity and Community 236Efficient Code 237The Bad of Libraries 238Overhead 238Performance 239Overreliance and Shelf Life 239Using Microlibraries 240The Good 240The Bad 241Summary 242Exercises 242Chapter 11: HTML5 JavaScript APIs 243What Is HTML5? 244The Markup (aka HTML) 244Creating Better Semantics 245Building More Accessible Content 245The JavaScript APIs 248The navigator Object 248Geolocation 249Audio and Video 251History API 254Web Workers 259Device API 265The Battery Status API 266The Vibration API 267The Network Information API 268Using This Today with Feature Detection 270Summary 271Exercises 272Chapter 12: Moving Forward with JavaScript 273A Brief Review of Key Topics 274Progressive Enhancement 274DOM Manipulation 275Data Storage 277Server Communication 279JavaScript for Designers 279Advanced Interface Design 280CSS Transforms in JavaScript 284Interacting from the Desktop 289JavaScript for Developers 293JavaScript Templates 294JavaScript on the Server with NodeJS 299Summary 302Exercises 303Answers 305Index 309
There are no comments on this title.