Reliable JavaScriptReliable JavaScript demonstrates how to create test-driven development for large-scale JavaScript applications that will stand the test of time and stay accurate through long-term use and maintenance. Taking a test-first approach to software architecture, this book walks you through several patterns and practices and explains what they are supposed to do by having you write unit tests. Write the code to pass the unit tests, so you not only develop your technique for structuring large-scale applications, but you also learn how to test your work. You'll come away with hands-on practice that results in code that is correct from the start, and has the test coverage to ensure that it stays correct during subsequent maintenance. All code is provided both in the text and on the web, so you can immediately get started designing more complete, robust applications.
JavaScript has graduated from field-validation scripts to full-scale applications, but many developers still approach their work ...
Learning Behavior-driven Development with JavaScriptJavaScript is not only widely used to create attractive user interfaces for the Web, but with the advent of Node.js, it is also becoming a very popular and powerful language to write server-side applications. Using behavior-driven development and some common testing patterns and best practices, you will be able to avoid these traps.
This book will show you how to do BDD in a practical way. We will start with a basic introduction of what BDD is and why the classical approach to testing has failed. Afterwards, we will dive directly into an introduction to Node.js, Mocha, and Sinon.JS. Finally, we will cover more advanced subjects such as how to write a fast and effective test suite for a RESTful web API, and how to do the same with a rich UI using Cucumber.js and Protractor.
This book will give you great insight into how to architect your system to make it more testable and modular, but at the same time avoid the nightmare of abusing mock objects. ...
Learning Network Programming with JavaNetwork-aware applications are becoming more prevalent and play an ever-increasing role in the world today. Connecting and using an Internet-based service is a frequent requirement for many applications. Java provides numerous classes that have evolved over the years to meet evolving network needs. These range from low-level socket and IP-based approaches to those encapsulated in software services.
This book explores how Java supports networks, starting with the basics and then advancing to more complex topics. An overview of each relevant network technology is presented followed by detailed examples of how to use Java to support these technologies.
We start with the basics of networking and then explore how Java supports the development of client/server and peer-to-peer applications. The NIO packages are examined as well as multitasking and how network applications can address practical issues such as security. ...
Beginning NetBeans IDEBeginning NetBeans IDE is your authoritative guide for getting started learning and using the free and open source NetBeans IDE. Written by Geertjan Wielenga, who has worked on the NetBeans Team since 2004, it shows you what the IDE is all about and how to use it with real-world case studies built from the ground up as you learn all about the IDE.
In this book, you get a tour of the various, essential, and key NetBeans features, including a range of wizards and plug-ins. Then, you start building a more complex Java EE-based application using Maven with the NetBeans IDE. And, you learn how to improve that application by exploring the NetBeans refactoring, testing, debugging, and profiling tools.
After reading and using this guide, you'll come away with a working case study and many insights into how to understand and optimally make use of NetBeans IDE. ...
Advanced Java EE Development with WildFlyThis book starts with an introduction to EJB 3 and how to set up the environment, including the configuration of a MySQL database for use with WildFly. We will then develop object-relational mapping with Hibernate 4, build and package the application with Maven, and then deploy it in WildFly 8.1, followed by a demonstration of the use of Facelets in a web application.
Moving on from that, we will create an Ajax application in the Eclipse IDE, compile and package it using Maven, and run the web application on WildFly 8.1 with a MySQL database. In the final leg of this book, we will discuss support for generating and parsing JSON with WildFly 8.1. ...
Appcelerator Titanium Smartphone App Development Cookbook, 2nd EditionThe mobile web has paved the way but many users want to have “native” applications installed. Using Appcelerator as a platform it's now possible to write iOS, Android, and Windows phone applications in JavaScript! It allows developers to develop fully native UI applications using Appcelerator studio tools without any knowledge of Objective-C, Swift or Java.
This book will take you through the process of building cross-platform, native UI applications for the mobile from scratch. You will learn how to develop apps, how to use GPS, cameras and photos and how to build socially connected apps. You will also learn how to package them for submission to the App Store and Google Play. ...
Build your own 2D Game Engine and Create Great Web GamesBuild Your Own 2D Game Engine and Create Great Web Games teaches you how to develop your own web-based game engine step-by-step, allowing you to create a wide variety of online videogames that can be played in common web browsers. Chapters include examples and projects that gradually increase in complexity while introducing a ground-up design framework, providing you with the foundational concepts needed to build fun and engaging 2D games. By the end of this book you will have created a complete prototype level for a side scrolling action platform game and will be prepared to begin designing additional levels and games of your own.
This book isolates and presents relevant knowledge from software engineering, computer graphics, mathematics, physics, game development, game mechanics, and level design in the context of building a 2D game engine from scratch. The book then derives and analyzes the source code needed to implement these concepts based on HTML5, JavaScript, and WebGL. ...
Learning JavaScript, 3rd EditionIf you're a programmer new to JavaScript, or even a beginner with little or no programming experience, this latest edition of practical book offers complete, no-nonsense coverage of this essential web development language. Learning JavaScript follows proven learning principles to help you absorb the concepts at an easy pace, so you'll learn how to create powerful and responsive applications in any browser.
Rather than simply teach JavaScript as an imperative language, author Ethan Brown (Web Development with Node and Express) introduces functional and asynchronous programming concepts early and reinforces them often. This book also gives equal preference to JavaScript's use as a "traditional" language (with filesystem and console access) and to its use as a browser-based language. ...
Introduction to JavaScript Object NotationWhat is JavaScript Object Notation (JSON) and how can you put it to work? This concise guide helps busy IT professionals get up and running quickly with this popular data interchange format, and provides a deep understanding of how JSON works. Author Lindsay Bassett begins with an overview of JSON syntax, data types, formatting, and security concerns before exploring the many ways you can apply JSON today.
From Web APIs and server-side language libraries to NoSQL databases and client-side frameworks, JSON has emerged as a viable alternative to XML for exchanging data between different platforms. If you have some programming experience and understand HTML and JavaScript, this is your book.
Learn why JSON syntax represents data in name-value pairs; Explore JSON data types, including object, string, number, and array; Find out how you can combat common security concerns; Learn how the JSON schema verifies that data is formatted correctly; Examine the relationship between browsers, w ...
Coding with JavaScript For DummiesCoding with JavaScript For Dummies provides easy, hands-on instruction for anyone looking to learn this popular client-side language. No experience? No problem! This friendly guide starts from the very beginning and walks you through the basics, then shows you how to apply what you've learned to real projects. You'll start building right away, including web page elements and simple applications, so you can immediately see how JavaScript is used in the real world. Online exercises allow you to test your code and expand your skills, and the easy-to-follow instruction provides step-by-step guidance toward understanding the JavaScript syntax, applications, and language.
JavaScript enhances static web pages by providing dynamic elements that can adapt and react to user action. It's a need-to-know tool for aspiring web designers, but anyone can benefit from understanding this core development language. ...
Enyo: Up and Running, 2nd EditionDiscover how easy it is to design and build responsive, cross-platform apps with the Enyo open source JavaScript framework. With this revised and expanded edition, Enyo contributor Roy Sutton gets you started with the framework's core object-oriented features, including its modular design, reusable and extensible components, layout and widget libraries, easy-to-use deployment options, and support for HTML5 standards.
You'll also delve into Enyo's latest features, including models, collections, data binding, and computed properties. Before you know it, you'll be writing native-quality, data-driven apps that work equally well on smartphones, tablets, and desktops. Are you familiar with HTML, CSS, or JavaScript? Then you're ready for Enyo. ...