Book Image

Introducing Dart [Video]

By : James Slocum
Book Image

Introducing Dart [Video]

By: James Slocum

Overview of this book

<p>As the internet becomes more of an application platform, the need to develop more feature-rich and immersive applications grows! Dart is a fantastic class-based, object-oriented language that pushes back on the idea that JavaScript should have a monopoly on web application development. It can be used both server side (dartVM) and client side (web browser) to build any application from a simple script to a full-blown 3D web game.</p> <p>Introducing Dart&nbsp;is a joyride of game programming where the user harnesses the power of the Dart programming language. The techniques shown in these videos can easily be applied and expanded upon to create any kind of interactive web application.</p> <p>We begin by learning how to install the Dart development environment, and how to get started using the Dart Editor. We then walk through building our game step-by-step until we are left with a fully functional game called “Dart Worm”.</p> <p>At the first step you will be introduced to the Dart SDK and the Dart editor software. This will provide the environment where we will design and develop our main project. Then you will learn how to use Dart to access the elements on a web page (called the DOM). Once these elements are accessed you will be shown how to manipulate them by calling methods, and how to add and remove elements from the DOM dynamically.</p> <p>As we move on we will be covering specific Dart classes that will help us bring the different components of our game to life. We will learn how to animate our game, keep score, and present the user with controls. Eventually, we will be putting everything we learned together and building our final game.</p> <p>When you have completed these videos, you will have all of the tools necessary to build and deploy a fully functional web application using the Dart programming language.</p> <h1>Style and Approach</h1> <p>This course is a step-by-step tutorial where each task is broken down and covered in detail to be easy to follow and implement. All of the source code is shown in each step, and any “gotchas” or “pitfalls” are exposed and explained completely.</p>
Table of Contents (6 chapters)
Chapter 1
Getting Started with the Dart Editor
Content Locked
Section 5
Getting the HTML and CSS for the Game in Place
Before we can start creating a web application, we need to lay out the template HTML and CSS. We will add HTML and CSS to our project so that we can begin adding worms and food on the screen. - Now that we have the layout for our WormGame, going forward, we will build upon this one project in each video - Open index.html and begin writing HTML for the game board and general layout - We open the worm.css file and start styling our elements so that we can use them - Test the styles by running the project with the Dart editor