Write Web Apps with Dart: Develop and Design

Write Web Apps with Dart: Develop and Design

by Jack Murphy

NOOK Book(eBook)

$15.99 $27.99 Save 43% Current price is $15.99, Original price is $27.99. You Save 43%.
View All Available Formats & Editions

Available on Compatible NOOK Devices and the free NOOK Apps.
WANT A NOOK?  Explore Now


DART, THE OPEN-SOURCE web programming language developed by Google, is designed for building everything from simple console utilities to full-featured applications for browsers and mobile devices. The Dart language is both familiar for seasoned engineers and easy to learn for aspiring programmers.

To get you up and productive, Dart developer Jack Murphy presents a series of solutions that a modern full stack developer will need to become proficient and launch a production application using Dart. In addition to a language introduction and overview, Jack builds a web application that will provide an easy-to-follow walkthrough of the Dart language and its associated development environments for both front-end and back-end programming. Jack’s web application implements a series of asynchronous browser components using Angular 2 Dart, while also leveraging Dart’s server capabilities to create a Dart-powered REST API.

• Detailed instruction, ample illustrations, and clear examples
• Real-world guidance and advice
• Insight into best practices from a Dart developer

CORRESPONDING GITHUB PROJECT (https://github.com/rightisleft/web_apps_dart) is included so that you can follow along with the examples in the video.

Two additional chapters with up-to-date material on the Angular 2 framework are available at www.peachpit.com.

Product Details

ISBN-13: 9780134214306
Publisher: Pearson Education
Publication date: 12/09/2015
Series: Develop and Design
Sold by: Barnes & Noble
Format: NOOK Book
Pages: 99998
File size: 14 MB
Note: This product may take a few minutes to download.

About the Author

Jack Murphy is seasoned technology product  and software engineering specialist with a full stack development and UI/UX background. He specializes in front-end client architecture for complex interactive applications. He has comprehensive industry experience as a UI-IXD / product designer along with deep front-end software engineering expertise. Jack has a passion for design and technology, and use both of these to create rich, engaging, dynamic user experiences for web products. He enjoys working on new and innovative platforms, and has helped scale multiple platforms and companies, from small teams prelaunch to multi-team workforces with multiple public-facing products supporting millions of monthly active users.

Table of Contents

Introduction x

Welcome to Dart xiv

Part I The Dart Language and Ecosystem

Chapter 1 Dart and The History of Browser Languages 2

The Web and Open Standards 4

JavaScript Deficits 4

Modern Alternatives 5

ECMAScript 4 5

Dash Memo 6

Google's Market Strategy 7

Summary 11

Chapter 2 Up and Running with Dart 12

Installing the Dart SDK 14

Dart Environmental Variables 15

IntelliJ IDEA Editor 17

Optional Homebrew 28

Summary 29

Chapter 3 Introduction to the Dart Language 30

Creating Your First Dart Project 32

Using Functions in Dart 33

Dart Objects and Maps 41

Statements and Control Structures 43

Errors on assert() 47

Collections and Iterators 47

Numbers 49

Summary 53

Chapter 4 Object Structures in Dart 54

Variables 56

Lexical Scope 56

Classes 61

Class Constructors 63

Constants 71

Class Inheritance 73

Polymorphism 76

Abstract Methods 78

Super Constructors 79

Interfaces 82

Mixins 84

Summary 86

Chapter 5 Packages and Libraries 88

Your First Library 90

Visibility and Privacy 94

Part and part of 98

Packages and pubspec.yaml 102

Named Package Imports 104

Summary 105

Chapter 6 Event Loops and Asynchronous Programming 106

Concurrent Computing Paradigm 108

Futures, Completers, and Streams 109

Streams 112

Event Loop 114

Async 115

Summary 118

Part II Full-Stack App Development with Dart

Chapter 7 Planning the Application 122

Fictitious Company Background 124

Feature Requests 124

Data Entities 126

Architecture Choices 132

Summary 133

Chapter 8 Introduction to Mongodb 134

Relational vs. NoSQL Databases 136

Why Not Database X? 137

What Is MongoDB? 137

Installing MongoDB 138

The Mongo Client 140

Summary 147

Chapter 9 Monco Dart 148

Setting Up Your Project 150

Downloading and Installing Mongo Dart Packages 151

Exposing Database Credentials 153

Seeding Data in Dart 153

Reading a File from the File System 155

Converting to JSON 157

Connecting to Mongo from Dart 159

Verifying the Data 162

Summary 163

Chapter 10 Data Modeling Using Dartson 164

Why Dartson 166

Mongo Pooling 167

Dartson Serialization 169

Creating a MongoModel with CRUD 174

Summary 183

Chapter 11 Webserver and Middleware 184

Shelf 186

Setting Up a Shelf Example 186

Adding Middleware 188

Adding Routing 191

Serving Static Assets 193

Using Multiple Handlers 194

Summary 197

Chapter 12 Api Routing, Requests, and Responses 198

Modeling Your Ticketing Domain 200

Implementing Controllers 206

Handling Routes 211

Summary 213

Chapter 13 Unit Testing Your Code 214

What Is Unit Testing? 216

Jasmine via Guinness 216

Setting Up Guinness 217

Composition of a Guinness Test 217

Testing Mongo 220

Summary 227

Chapter 14 A Web Project With Dart 228

Planning for Front-End Development 230

Interacting with HTML and the DOM 232

Querying the DOM 235

Building the Landing Page 238

Summary 245

Chapter 15 Introduction to Angular 2 Dart 246

The History of AngularJS and Angular Dart 248

Typescript 248

Developer Preview Warning 249

Angular 2 Overview 250

Summary 265

Congratulations! 266

Index 267

Online Chapters

Chapter 16 Angular Component Implementation and Business Logic (Available Online) xiii

Chapter 17 Deploying to Production Servers (available online) xiii

Customer Reviews

Most Helpful Customer Reviews

See All Customer Reviews