Head First JavaScript Programming Eric T. Freeman, Elisabeth Robson
Head First JavaScript Programming Eric T. Freeman, Elisabeth Robson
759 ₴
Немає в наявності
Доставка
Детальніше про доставку
Оплата
Характеристики
Тип
друковане видання
Вікова категорія
для дорослих
Состояние
новый
Опис
What will you learn from this book? Це приємно керує інструментами, які висловлюють, що з JavaScript англійською мовою принципи до розширених топиків, включаючи objects, functions, і browser's document object model. You won't just be reading—you'll be playing games, solving puzzles, pondering mysteries, and interacting with JavaScript in ways you never imagined. And you'll напишіть реальний код, багато його, так що ви можете налаштовувати ваші власні web applications. Prepare to open your mind as you learn (and nail) key topics including: Inner details of JavaScript How JavaScript works with browser The secrets of JavaScript types Using arrays Power functions How to work with objects Making use of prototypes Understanding closures and testing applications What's so special about this book? Ми думаємо, що цей час є важливим для того, щоб боротися з новою концепцією. Використовуючи останні дослідження в cognitive science and learning theory to craft a multi-sensory learning experience, Head First JavaScript Programming use a visually rich format designed for way your brain works, no text-heavy approach that puts you to sleep. Chapter 1 : A Quick Dip in Javascript: Використовуйте вашу пошту wet the way JavaScript works How you're going to write JavaScript How to get JavaScript into your page JavaScript, you've come a long way baby... How to make a statement Variables and values Back away from that keyboard! Express yourself Doing things more than once How the while loop works Making decisions with JavaScript And, when you need to make LOTS of decisions Ви можете повідомити і комунікувати з вашим користувачем closer look at console.log Opening the console Coding a Serious JavaScript Application How do I add code to my page? (Лет мені County ways) Ви шукаєте, щоб separate you two Chapter 2 : Записуючий Real Code: Going further Let's build a Battleship game Ваша перша attempt... First, high-level design A few more details.. Working through the Pseudocode Oh, before we go any further, don't forget the HTML! Записуючи Simple Battleship code Now let's write the game logical Step One: setting up the loop, get sem input How prompt works Checking the user's guess So, do we have a hit? Adding the hit detection code Hey, you sank my battleship! Provide some post-game analysis And that completes the logic! Прийнятий малу якість візуалізації може бути мова про вашу verbosity... Finishing Simple Battleship game How to assign random locations The world-famous recipe for generating a random number a short word o reusing code Chapter 3 : Introducing Functions: Get functional What's wrong with the code anyway? By the way, did we happen to mention FUNCTIONS? Okay, але як це робиться в даний час? What can you pass to a function? JavaScript є pass-by-value. Weird Functions Functions can return things too Tracing через function with return statement Global and local variables Досліджуючи скопію ваших місцевих і національних варіалів Шорти прави варіативів Не маю forget to declare your locals! Chapter 4 : Putting Some Order in Your Data: Мапа Canyou help Bubbles-R-Us? Якою є величезні значення в JavaScript Чималі робочі роботи Чим access array item Updating a value in the array Який великий є те, що array anyway? The Phrase-O-Matic Meanwhile, back at Bubbles-R-Us... How to iterate over an array But wait, there's better way to iterate over an array It's that time again.... Can we talk about your verbosity ? Переміщення для вимкнення з післявимірювальним оператором Quick test drive Створення аріалу з шорти (і з'єднує з ним) And winners are... A quick survey of the code... Writing the printAndGetHighScore функція Refactoring the code using printAndGetHighScore it all together... Chapter 5 : Understanding Objects: A trip to Objectville Did someone say “Objects”?! Подумайте про свої властивості... Як створити object What is Object-Oriented Anyway? How properties work How does variable hold an object? Захоплюючі мандрівки хочуть пізнати... Порівняти прімітиви і objects Doing even more with objects... Stepping through pre-qualification З'єднуйся як мало більше про passing objects to functions Oh Behave! Or, як додати бігу до своїх об'єктів Improving drive method Why doesn't drive method know про started property? How this works How behavior affects state... Додати деякий час Gas-o-line Новий рік's affect the behavior with the state Congrats on your first objects! Guess what? Там є об'єкти всі навколо вас! (Адже вони роблять вашого життя еазіер) Chapter 6 : Interacting with Your Web Page: Завантажити DOM в наш останній шаптер, будь ласка з маленьким challenge. The “crack the code challenge.” So what does the code do? How JavaScript реально interacts with your page How to bake your very own DOM Як перше випробування DOM Дім елемента з getElementById What, exactly, am I getting from the DOM? Відправляйте свій вбудований HTML HTML Який спосіб, коли ви змінюєте ДОМ Оцінка керування за планетами Не треба думати про те, що мова коду until page fully loaded! You say “event hander,” I say “callback” How to set an atribute with setAttribute Більше fun with attributes! (можна GET attributes too) Яке це є DOM good for anyway? Chapter 7 : Types, Equality, Conversion and All That Jazz: Serious types The truth is out there... Watch out, you might bump in undefined when you aren't expecting it... How to use null Dealing with NaN It gets even weirder Ви маєте confession to make Understanding the equality operator (otherwise known as ==) How equality converts its operands (sounds more dangerous than it actually is) How to get strict with equality Even more Два об'єкта є еквівалентом truthy is out there... What JavaScript consideras falsey Секретний життя Strings Чим string can look like a primitive and object 5-minute tour of string methods (and properties) Chair Wars (or How Really Зображення Types Can Change Your Life) Chapter 8 : Bringing it All Together: Building app This time, let's build a REAL Battleship game Stepping back... до HTML і CSS Створення HTML сторінок: Big Picture Adding some more style Using the hit and miss classes How design game Implementing the View How displayMessage works How displayHit and displayMiss work The Model How we're going to represent the ships Implementing the model object Setting up the fire method Implementing the Controller Processing the player's guess ... Implementing parseGuess Counting guesses and firing the shot How to add event handler to the Fire! Кнопка 9 : Asynchronous Coding: Handling events What are events? What's an event handler? Як створити вашу першу позицію мандрівника Test drive your event Getting your head around events... by creating a game Implementing the game Test drive Знайомте більше зображення Той самий handler для всіх зображень Хоч event object works Putting event object to work Test drive the event object and target Events and queues Even more events How setTimeout works Functions The mysterious double life of the function keyword Function Declarations versus Function Expressions Пісні функції Function Declaration What's next? browser executes code Мовить на... Додаткові сили функцій є значеннями Did we mention functions have First Class status in JavaScript? Flying First Class Writing code to process and check passengers Iterating through the passengers Passing a function to a function Returning functions from functions Writing the flight attendant drink order code How array sort method works Putting it all together Take sorting for test drive Chapter 11 : Anonymous Functions, Scope and Closures: Serious functions Використовуючи на іншій стороні функцій... Як використовувати anonymous function Ваша verbosity, again When is a function defined? It depends... What just happened? Why wasn't fly defined? How to nest functions How nesting affects scope Малий відгук lexical scope Where things get interesting with lexical scope Functions Revisited Calling a function (revisited) What the heck is a closure? Змінити функцію За допомогою closures до здійснити магічний Counter Використовуючи підготовку... Створення closure by passing a function expression as argument The closure contains the actual environment, no Creating closure with event handler How the Click me! closure works Chapter 12 : Advanced Object Construction: Creating objects Creating objects with object literals Using conventions for objects Introducing Object Constructors Для створення конструктора Як використовувати constructor How constructors work You can put methods into constructors Let's test drive some new cars Чи не Count out object literals just yet Rewiring the arguments as object literal Reworking the Car constructor Understanding Object Instances Even constructed objects can have their own independent properties Real World Constructors Array object Even more fun with bu in objects Chapter 13 : За допомогою Prototypes: Extra strength objects Hey, перед тим, як бути здійсненим, ми будемо хотіти, щоб diagram наші об'єкти Revisiting object constructors: we'reusing code, but are we being efficient? Чи є duplicating methods really a problem? What є prototypes? Inheriting from prototype Now inheritance works Overriding the prototype How to set up the prototype Prototypes are dynamic A more interesting implementation of the sit method One more time: how the setting property works How to approach the design of show dogs Setting up a cha prototypes How inheritance works in prototype chain Створення show dog prototype Creating a show dog instance A final cleanup of show dogs Stepping через Ps. behavior Using inheritance to your advantage... extending a built-in object Grand Unified Theory of Better живе через objects Putting it all together What's next? Appendix : Leftovers: The top ten topics (we didn't cover) #1 jQuery #2 Doing more with the DOM #3 The Window Object #4 Arguments #5 Handling exceptions #6 Adding event handlers with addEventListener #7 Regular Expressions #8 Recursion #9 JSON #10 Server-side JavaScript Colophon
Дивіться також
Покупцям
Умови повернення та обміну