SlideShare a Scribd company logo
Structured Web Apps with
AGENDA 
► What is Dart? 
► How Dart Works 
► Dart Features 
► Language Tour 
► CASE DEMOS 
► Questions
WHAT IS DART? 
“...an open-source, batteries-included 
developer platform for 
building HTML5 web apps.” 
dartlang.org
BY GOOGLE 
Gilad Bracha 
Software Engineer 
Lars Bak 
Computer Programmer 
► HotSpot 
VM 
► V8 
JavaScript 
Engine 
► Dart 
VM 
► Newspeak 
Language 
► Java 
Language 
Spec 
► Dart 
Language 
Spec
TYPICAL WEB APP 
SCENARIO
“Hey, I want 
a web app”
“Hey, I want 
a web app” 
Backbone.JS
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js”
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...”
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS
“Hey, I want 
a web app” 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr
“Hey, I want 
a web app” 
jQueryUI 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr
“Hey, I want 
a web app” 
jQueryUI 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr 
Leaflet.JS
“Hey, I want 
a web app” 
jQueryUI 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr 
Leaflet.JS 
Jasmine BDD
“Hey, I want 
a web app” 
jQueryUI 
Backbone.JS 
“Backbone’s only hard dependency is Underscore.js” 
Raphael.JS 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr 
Leaflet.JS 
Jasmine BDD
“Hey, I want 
a web app” 
jQueryUI 
DOCS 
DOCS DOCS 
Backbone.JS 
DOCS 
“Backbone’s only hard dependency is Underscore.js” 
Raphael.JS 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr 
Leaflet.JS 
Jasmine BDD 
DOCS 
DOCS 
DOCS 
DOCS DOCS
“Hey, I want 
a web app” 
jQueryUI 
DOCS 
DOCS DOCS 
Backbone.JS 
DOCS 
“Backbone’s only hard dependency is Underscore.js” 
Raphael.JS 
Underscore.JS 
jQuery 
“For RESTful persistence, history support via 
Backbone.Router and DOM manipulation with 
Backbone.View, include jQuery...” 
Moment.JS 
Modernizr 
Leaflet.JS 
Jasmine BDD 
DOCS 
DOCS 
DOCS 
DOCS DOCS
CONSISTENT AND CLEAR 
DART SDK 
Packages 
MVC 
Web UI 
Unit test
OFFICIAL ECMA STANDARD 
ecma-international.org/publications/standards/Ecma-408.htm
DART BUNDLE 
IDE 
Dartium 
Dart SDK
DART BUNDLE 
IDE 
Dartium 
Dart SDK 
► Eclipse-based editor 
► Supports code completion, 
static analysis, Checked/ 
Production Mode etc… 
► Plugins for third-party IDE 
and Text-Editors
DART BUNDLE 
IDE 
Dartium 
Dart SDK 
► Eclipse-based editor 
► Supports code completion, 
static analysis, Checked/ 
Production Mode etc… 
► Plugins for third-party IDE 
and Text-Editors 
► Custom build of 
Chromium with 
the Dart VM
DART BUNDLE 
IDE 
Dartium 
Dart SDK 
► Eclipse-based editor 
► Supports code completion, 
static analysis, Checked/ 
Production Mode etc… 
► Plugins for third-party IDE 
and Text-Editors 
► Custom build of 
Chromium with 
the Dart VM 
► Dart VM, Core 
Libraries and 
Command line 
tools
COMMAND LINE TOOLS 
dart
COMMAND LINE TOOLS 
dart 
dartanalyzer
COMMAND LINE TOOLS 
dart 
dartanalyzer 
docgen
COMMAND LINE TOOLS 
dart 
dartanalyzer 
pub docgen
COMMAND LINE TOOLS 
dart 
dartanalyzer 
pub docgen 
dart2js
HOW DART WORKS 
index.dart
HOW DART WORKS 
index.dart 
Dart Virtual Machine 
standalone or browser
HOW DART WORKS 
index.dart 
Dart-to-JavaScript 
compiler 
Dart Virtual Machine 
standalone or browser
HOW DART WORKS 
index.dart Dart Virtual Machine 
Dart-to-JavaScript 
compiler 
standalone or browser 
index.dart.js
FOR MODERN BROWSERS
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn()
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn() 
imports
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn() 
calls 
imports
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn() 
calls 
imports 
calls
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn() 
calls 
imports 
calls 
dart2js
TREE-SHAKING COMPILER 
Source Application 
main 
Library 
fn() 
fn() 
fn() 
fn() 
calls 
imports 
calls 
main 
calls 
calls 
fn() 
fn() 
dart2js
BENCHMARKS 
dart dart2js js 
dartlang.org/performance
WHO USES DART? 
dartlang.org/community/who-uses-dart.html
ADOBE 
toolki@ordart.github.io
BLOSSOM 
blossom.io
SOUNDTRAP 
soundtrap.com
ANGULAR 
angulardart.org
DART FEATURES
► Object-oriented language 
► Single-threaded 
► Asynchronous Programming 
with Futures/Streams 
► Concurrency with Isolates 
► Lexical Scoping 
► Modularity and Scalability
LANGUAGE TOUR
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth);! 
}! 
! 
void main() {! 
!Person person = new Person(“Joe Bloggs”, 1975);! 
!print(person.name);! 
}! 
!!
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth);! 
}! 
! 
void main() {! 
!Person person = new Person(“Joe Bloggs”, 1975);! 
!print(person.name);! 
}! 
!! 
Shorthand Constructors
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
}! 
! 
void main() {! 
!Person person = new Person.withDefaults();! 
!print(person.name);! 
}! 
!! 
Named Constructors
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
}! 
! 
void main() {! 
!Person person = new Person.withDefaults();! 
!print(person.name);! 
}! 
!! 
Initialised defaults
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth, {String nationality: ‘unknown’});! 
!Person.withDefaults() : this(‘No name’, 1768);! 
}! 
! 
void main() {! 
!Person person = new Person(“Joe Bloggs”, 1975, nationality: ‘UK’);! 
!print(person.name);! 
}! 
!! 
Optional named parameters
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
}! 
! 
void main() {! 
!Person person = new Person(“Joe Bloggs”, 1975, ‘UK’);! 
!print(person.name);! 
}! 
!! 
Optional positional parameters
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
!! 
!Person operator +(Person other) {! 
! !return new Person(name + ‘ and ‘ + other.name, 9999);! 
!}! 
} !! 
Operator overrides
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
!! 
!Person operator +(Person other) {! 
! !return new Person(name + ‘ and ‘ + other.name, 9999);! 
!}! 
! 
Shorthand functions 
!speak() => print(“$name is speaking”);! 
} !!
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
!! 
!Person operator +(Person other) {! 
! !return new Person(name + ‘ and ‘ + other.name, 9999);! 
!}! 
! 
!speak() => print(“$name is speaking”);! 
} !! 
String interpolation
class Person {! 
!String _name;! 
!int _yearOfBirth;! 
! 
!Person(this._name, this._yearOfBirth);! 
!Person.withDefaults() : this(‘No name’, 1768);! 
! 
!Person operator +(Person other) {! 
! !return new Person(name + ‘ and ‘ + other.name, 9999);! 
!}! 
! 
getters and setters 
!speak() => print(“$_name is speaking”);! 
! 
!String get name => _name;! 
! set name(String value) => _name = value;! 
} !!
METHOD CASCADES
import “dart:html”;! 
! 
void main() {! 
!! 
!InputElement button = new InputElement();! 
! ! ! !button.id = “sendButton”;! 
! ! ! !button.text = “Donate Bruv!!!”;! 
! ! ! !button.classes.add(‘please’);! 
! ! ! !button.onClick.listen((e) => print(‘thanks!’));! 
! 
!document.body.children.add(button);! 
! ! ! ! ! 
} !!
import “dart:html”;! 
! 
void main() {! 
!! 
!InputElement button = new InputElement();! 
! ! ! !button.id = “sendButton”;! 
! ! ! !button.text = “Donate Bruv!!!”;! 
! ! ! !button.classes.add(‘please’);! 
! ! ! !button.onClick.listen((e) => print(‘thanks!’));! 
! 
!document.body.children.add(button);! 
! ! ! ! ! 
} !!
import “dart:html”;! 
! 
void main() {! 
!! 
!InputElement button = new InputElement()! 
! ! ! !..id = “sendButton”! 
! ! ! !..text = “Donate Bruv!!!”! 
! ! ! !..classes.add(‘please’)! 
! ! ! !..onClick.listen((e) => print(‘thanks!’));! 
Method Cascades 
! 
!document.body.children.add(button);! 
! ! ! ! ! 
} !!
class Person {! 
!String name;! 
!int yearOfBirth;! 
! 
!Person({this.name, this.yearOfBirth});! 
! 
!speak() => print(“$name is speaking”);! 
}! 
! 
void main() {! 
!Person person = new Person()! 
! ! ! !..name = “Joe Bloggs”! 
! ! ! !..yearOfBirth = 1985! 
! ! ! !..speak();! 
! 
!print(person.name);! 
}! 
!!
MIXINS
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class Customer extends Person {! 
!String _name;! 
!Customer(this._name);! 
}! 
!!
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class VIPPermissions extends Person {! 
!luxuryTreatment() => print(“Your royal suite is ready!”);! 
}! 
! 
class Customer extends VIPPermissions {! 
!String _name;! 
!Customer(this._name);! 
}! 
!!
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class VIPPermissions extends Person {! 
!luxuryTreatment() => print(“Your royal suite is ready!”);! 
}! 
! 
class Customer extends VIPPermissions {! 
!String _name;! 
!Customer(this._name);! 
}! 
!! 
Customer 
IS 
NOT 
a 
VIPPermissions 
!!!
abstract class VIPPermissions {! 
!luxuryTreatment() => print(“Your royal suite is ready!”);! 
}! 
! 
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class Customer extends Person with VIPPermissions {! 
!String _name;! 
!Customer(this._name);! 
}! 
!!
abstract class VIPPermissions {! 
!luxuryTreatment() => print(“Your royal suite is ready!”);! 
}! 
! 
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class Customer extends Person with VIPPermissions {! 
!String _name;! 
!Customer(this._name);! 
}! 
! 
void main() {! 
!Customer customer = new Customer(‘Charles’)..luxuryTreatment();! 
}! 
!!
abstract class VIPPermissions {! 
!luxuryTreatment() => print(“Your royal suite is ready!”);! 
}! 
! 
class Person {! 
!speak() => print(“person is speaking”);! 
}! 
! 
class Customer extends Person with VIPPermissions {! 
!String _name;! 
!Customer(this._name);! 
}! 
! 
void main() {! 
!Customer customer = new Customer(‘Charles’)..luxuryTreatment();! 
}! 
!!
BUT THAT’S NOT ALL! 
► Generics 
► Mirrors/Reflections 
► Transformations 
► Metadata/ 
Annotations 
► Factories 
► Lazy-loading 
► Interoperate with JS 
► Observatory 
► Automatic 
Sanitization 
► Web Components 
► SIMD 
► and lots more…
JOIN THE DART SIDE 
► dartlang.org/codelabs 
► api.dartlang.org 
► pub.dartlang.org 
► @dartlang on Twitter
CASE DEMOS
THANK YOU.
Ad

More Related Content

What's hot (13)

建立前端開發團隊 - 2011 中華電信訓練所版
建立前端開發團隊 - 2011 中華電信訓練所版建立前端開發團隊 - 2011 中華電信訓練所版
建立前端開發團隊 - 2011 中華電信訓練所版
Joseph Chiang
 
jQuery for beginners
jQuery for beginnersjQuery for beginners
jQuery for beginners
Siva Arunachalam
 
Better Selenium Tests with Geb - Selenium Conf 2014
Better Selenium Tests with Geb - Selenium Conf 2014Better Selenium Tests with Geb - Selenium Conf 2014
Better Selenium Tests with Geb - Selenium Conf 2014
Naresha K
 
Learn css3
Learn css3Learn css3
Learn css3
Mostafa Bayomi
 
An in-depth look at jQuery UI
An in-depth look at jQuery UIAn in-depth look at jQuery UI
An in-depth look at jQuery UI
Paul Bakaus
 
Presentation for Linked Ancient World Data Institute
Presentation for Linked Ancient World Data InstitutePresentation for Linked Ancient World Data Institute
Presentation for Linked Ancient World Data Institute
dejp3
 
React.js & Om: A hands-on walkthrough of better ways to build web UIs
React.js & Om: A hands-on walkthrough of better ways to build web UIsReact.js & Om: A hands-on walkthrough of better ways to build web UIs
React.js & Om: A hands-on walkthrough of better ways to build web UIs
Adam Solove
 
Ten Ways to Destroy Your Database
Ten Ways to Destroy Your DatabaseTen Ways to Destroy Your Database
Ten Ways to Destroy Your Database
PostgreSQL Experts, Inc.
 
jQuery - 10 Time-Savers You (Maybe) Don't Know
jQuery - 10 Time-Savers You (Maybe) Don't KnowjQuery - 10 Time-Savers You (Maybe) Don't Know
jQuery - 10 Time-Savers You (Maybe) Don't Know
girish82
 
End-to-end testing with geb
End-to-end testing with gebEnd-to-end testing with geb
End-to-end testing with geb
Jesús L. Domínguez Muriel
 
Php Sq Lite
Php Sq LitePhp Sq Lite
Php Sq Lite
mussawir20
 
JQuery: JavaScript Library of the Future
JQuery: JavaScript Library of the FutureJQuery: JavaScript Library of the Future
JQuery: JavaScript Library of the Future
Matthew Taylor
 
Jquery ui
Jquery uiJquery ui
Jquery ui
adm_exoplatform
 
建立前端開發團隊 - 2011 中華電信訓練所版
建立前端開發團隊 - 2011 中華電信訓練所版建立前端開發團隊 - 2011 中華電信訓練所版
建立前端開發團隊 - 2011 中華電信訓練所版
Joseph Chiang
 
Better Selenium Tests with Geb - Selenium Conf 2014
Better Selenium Tests with Geb - Selenium Conf 2014Better Selenium Tests with Geb - Selenium Conf 2014
Better Selenium Tests with Geb - Selenium Conf 2014
Naresha K
 
An in-depth look at jQuery UI
An in-depth look at jQuery UIAn in-depth look at jQuery UI
An in-depth look at jQuery UI
Paul Bakaus
 
Presentation for Linked Ancient World Data Institute
Presentation for Linked Ancient World Data InstitutePresentation for Linked Ancient World Data Institute
Presentation for Linked Ancient World Data Institute
dejp3
 
React.js & Om: A hands-on walkthrough of better ways to build web UIs
React.js & Om: A hands-on walkthrough of better ways to build web UIsReact.js & Om: A hands-on walkthrough of better ways to build web UIs
React.js & Om: A hands-on walkthrough of better ways to build web UIs
Adam Solove
 
jQuery - 10 Time-Savers You (Maybe) Don't Know
jQuery - 10 Time-Savers You (Maybe) Don't KnowjQuery - 10 Time-Savers You (Maybe) Don't Know
jQuery - 10 Time-Savers You (Maybe) Don't Know
girish82
 
JQuery: JavaScript Library of the Future
JQuery: JavaScript Library of the FutureJQuery: JavaScript Library of the Future
JQuery: JavaScript Library of the Future
Matthew Taylor
 

Viewers also liked (13)

Cloudformation
CloudformationCloudformation
Cloudformation
Duangtida Phrommakhot
 
Анжеро-Судженск бюджет 2015
Анжеро-Судженск бюджет 2015Анжеро-Судженск бюджет 2015
Анжеро-Судженск бюджет 2015
anzhero
 
304 304 l-data-sheets-1-28-13
304 304 l-data-sheets-1-28-13304 304 l-data-sheets-1-28-13
304 304 l-data-sheets-1-28-13
Wander Santos
 
リメディアル教育学会・発表1
リメディアル教育学会・発表1リメディアル教育学会・発表1
リメディアル教育学会・発表1
Keiji Shibata
 
Area sales manager kpis
Area sales manager kpisArea sales manager kpis
Area sales manager kpis
hanperaca
 
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
anzhero
 
Анжеро-Судженск исполнение 2015 г.
Анжеро-Судженск исполнение 2015 г.Анжеро-Судженск исполнение 2015 г.
Анжеро-Судженск исполнение 2015 г.
anzhero
 
Lecture 4 (part c) empirical models
Lecture 4 (part c)   empirical modelsLecture 4 (part c)   empirical models
Lecture 4 (part c) empirical models
penalissthima
 
Debloquer samsung gratuit
Debloquer samsung gratuitDebloquer samsung gratuit
Debloquer samsung gratuit
Oscar Faure
 
Instagram for Ecommerce Marketing
Instagram for Ecommerce MarketingInstagram for Ecommerce Marketing
Instagram for Ecommerce Marketing
Ella Smith
 
Бюджет для граждан 2015
Бюджет для граждан 2015Бюджет для граждан 2015
Бюджет для граждан 2015
anzhero
 
Бюджет для граждан 2014
Бюджет для граждан 2014Бюджет для граждан 2014
Бюджет для граждан 2014
anzhero
 
Logowanie do-platformy-edu-spoldzielnie
Logowanie do-platformy-edu-spoldzielnieLogowanie do-platformy-edu-spoldzielnie
Logowanie do-platformy-edu-spoldzielnie
hotelbania
 
Анжеро-Судженск бюджет 2015
Анжеро-Судженск бюджет 2015Анжеро-Судженск бюджет 2015
Анжеро-Судженск бюджет 2015
anzhero
 
304 304 l-data-sheets-1-28-13
304 304 l-data-sheets-1-28-13304 304 l-data-sheets-1-28-13
304 304 l-data-sheets-1-28-13
Wander Santos
 
リメディアル教育学会・発表1
リメディアル教育学会・発表1リメディアル教育学会・発表1
リメディアル教育学会・発表1
Keiji Shibata
 
Area sales manager kpis
Area sales manager kpisArea sales manager kpis
Area sales manager kpis
hanperaca
 
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
Анжеро-Судженск. Проект бюджет для граждан на 2017 г.
anzhero
 
Анжеро-Судженск исполнение 2015 г.
Анжеро-Судженск исполнение 2015 г.Анжеро-Судженск исполнение 2015 г.
Анжеро-Судженск исполнение 2015 г.
anzhero
 
Lecture 4 (part c) empirical models
Lecture 4 (part c)   empirical modelsLecture 4 (part c)   empirical models
Lecture 4 (part c) empirical models
penalissthima
 
Debloquer samsung gratuit
Debloquer samsung gratuitDebloquer samsung gratuit
Debloquer samsung gratuit
Oscar Faure
 
Instagram for Ecommerce Marketing
Instagram for Ecommerce MarketingInstagram for Ecommerce Marketing
Instagram for Ecommerce Marketing
Ella Smith
 
Бюджет для граждан 2015
Бюджет для граждан 2015Бюджет для граждан 2015
Бюджет для граждан 2015
anzhero
 
Бюджет для граждан 2014
Бюджет для граждан 2014Бюджет для граждан 2014
Бюджет для граждан 2014
anzhero
 
Logowanie do-platformy-edu-spoldzielnie
Logowanie do-platformy-edu-spoldzielnieLogowanie do-platformy-edu-spoldzielnie
Logowanie do-platformy-edu-spoldzielnie
hotelbania
 
Ad

Similar to Structured Apps with Google Dart (20)

Getting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot FrameworkGetting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot Framework
Sarah Sexton
 
Word Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with TraceryWord Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with Tracery
Sarah Sexton
 
Sprockets
SprocketsSprockets
Sprockets
Christophe Porteneuve
 
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
BradNeuberg
 
How to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrainHow to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrain
Codemotion Tel Aviv
 
Cheap frontend tricks
Cheap frontend tricksCheap frontend tricks
Cheap frontend tricks
ambiescent
 
Web Development Study Jam #2 _ Basic JavaScript.pptx
Web Development Study Jam #2 _ Basic JavaScript.pptxWeb Development Study Jam #2 _ Basic JavaScript.pptx
Web Development Study Jam #2 _ Basic JavaScript.pptx
SekarMaduKusumawarda1
 
I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)
Joel Lord
 
Going live with BommandBox and docker Into The Box 2018
Going live with BommandBox and docker Into The Box 2018Going live with BommandBox and docker Into The Box 2018
Going live with BommandBox and docker Into The Box 2018
Ortus Solutions, Corp
 
Into The Box 2018 Going live with commandbox and docker
Into The Box 2018 Going live with commandbox and dockerInto The Box 2018 Going live with commandbox and docker
Into The Box 2018 Going live with commandbox and docker
Ortus Solutions, Corp
 
Free The Enterprise With Ruby & Master Your Own Domain
Free The Enterprise With Ruby & Master Your Own DomainFree The Enterprise With Ruby & Master Your Own Domain
Free The Enterprise With Ruby & Master Your Own Domain
Ken Collins
 
Backbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVCBackbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVC
pootsbook
 
前端概述
前端概述前端概述
前端概述
Ethan Zhang
 
Fantom and Tales
Fantom and TalesFantom and Tales
Fantom and Tales
kaushik_sathupadi
 
Jquery presentation
Jquery presentationJquery presentation
Jquery presentation
guest5d87aa6
 
GDI Seattle - Intro to JavaScript Class 4
GDI Seattle - Intro to JavaScript Class 4GDI Seattle - Intro to JavaScript Class 4
GDI Seattle - Intro to JavaScript Class 4
Heather Rock
 
What’s new in Google Dart - Seth Ladd
What’s new in Google Dart - Seth LaddWhat’s new in Google Dart - Seth Ladd
What’s new in Google Dart - Seth Ladd
jaxconf
 
GraphQL & Relay - 串起前後端世界的橋樑
GraphQL & Relay - 串起前後端世界的橋樑GraphQL & Relay - 串起前後端世界的橋樑
GraphQL & Relay - 串起前後端世界的橋樑
Pokai Chang
 
"Writing Maintainable JavaScript". Jon Bretman, Badoo
"Writing Maintainable JavaScript". Jon Bretman, Badoo"Writing Maintainable JavaScript". Jon Bretman, Badoo
"Writing Maintainable JavaScript". Jon Bretman, Badoo
Yandex
 
Copy/paste detector for source code on javascript
Copy/paste detector for source code on javascript Copy/paste detector for source code on javascript
Copy/paste detector for source code on javascript
Andrey Kucherenko
 
Getting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot FrameworkGetting Started with Microsoft Bot Framework
Getting Started with Microsoft Bot Framework
Sarah Sexton
 
Word Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with TraceryWord Play in the Digital Age: Building Text Bots with Tracery
Word Play in the Digital Age: Building Text Bots with Tracery
Sarah Sexton
 
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
Beyond Cookies, Persistent Storage For Web Applications Web Directions North ...
BradNeuberg
 
How to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrainHow to actually use promises - Jakob Mattsson, FishBrain
How to actually use promises - Jakob Mattsson, FishBrain
Codemotion Tel Aviv
 
Cheap frontend tricks
Cheap frontend tricksCheap frontend tricks
Cheap frontend tricks
ambiescent
 
Web Development Study Jam #2 _ Basic JavaScript.pptx
Web Development Study Jam #2 _ Basic JavaScript.pptxWeb Development Study Jam #2 _ Basic JavaScript.pptx
Web Development Study Jam #2 _ Basic JavaScript.pptx
SekarMaduKusumawarda1
 
I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)I Don't Care About Security (And Neither Should You)
I Don't Care About Security (And Neither Should You)
Joel Lord
 
Going live with BommandBox and docker Into The Box 2018
Going live with BommandBox and docker Into The Box 2018Going live with BommandBox and docker Into The Box 2018
Going live with BommandBox and docker Into The Box 2018
Ortus Solutions, Corp
 
Into The Box 2018 Going live with commandbox and docker
Into The Box 2018 Going live with commandbox and dockerInto The Box 2018 Going live with commandbox and docker
Into The Box 2018 Going live with commandbox and docker
Ortus Solutions, Corp
 
Free The Enterprise With Ruby & Master Your Own Domain
Free The Enterprise With Ruby & Master Your Own DomainFree The Enterprise With Ruby & Master Your Own Domain
Free The Enterprise With Ruby & Master Your Own Domain
Ken Collins
 
Backbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVCBackbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVC
pootsbook
 
Jquery presentation
Jquery presentationJquery presentation
Jquery presentation
guest5d87aa6
 
GDI Seattle - Intro to JavaScript Class 4
GDI Seattle - Intro to JavaScript Class 4GDI Seattle - Intro to JavaScript Class 4
GDI Seattle - Intro to JavaScript Class 4
Heather Rock
 
What’s new in Google Dart - Seth Ladd
What’s new in Google Dart - Seth LaddWhat’s new in Google Dart - Seth Ladd
What’s new in Google Dart - Seth Ladd
jaxconf
 
GraphQL & Relay - 串起前後端世界的橋樑
GraphQL & Relay - 串起前後端世界的橋樑GraphQL & Relay - 串起前後端世界的橋樑
GraphQL & Relay - 串起前後端世界的橋樑
Pokai Chang
 
"Writing Maintainable JavaScript". Jon Bretman, Badoo
"Writing Maintainable JavaScript". Jon Bretman, Badoo"Writing Maintainable JavaScript". Jon Bretman, Badoo
"Writing Maintainable JavaScript". Jon Bretman, Badoo
Yandex
 
Copy/paste detector for source code on javascript
Copy/paste detector for source code on javascript Copy/paste detector for source code on javascript
Copy/paste detector for source code on javascript
Andrey Kucherenko
 
Ad

Recently uploaded (20)

Mastering Advance Window Functions in SQL.pdf
Mastering Advance Window Functions in SQL.pdfMastering Advance Window Functions in SQL.pdf
Mastering Advance Window Functions in SQL.pdf
Spiral Mantra
 
MINDCTI revenue release Quarter 1 2025 PR
MINDCTI revenue release Quarter 1 2025 PRMINDCTI revenue release Quarter 1 2025 PR
MINDCTI revenue release Quarter 1 2025 PR
MIND CTI
 
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
organizerofv
 
Semantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AISemantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AI
artmondano
 
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
BookNet Canada
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager APIUiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPathCommunity
 
Top 10 IT Help Desk Outsourcing Services
Top 10 IT Help Desk Outsourcing ServicesTop 10 IT Help Desk Outsourcing Services
Top 10 IT Help Desk Outsourcing Services
Infrassist Technologies Pvt. Ltd.
 
Social Media App Development Company-EmizenTech
Social Media App Development Company-EmizenTechSocial Media App Development Company-EmizenTech
Social Media App Development Company-EmizenTech
Steve Jonas
 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
 
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath MaestroDev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
UiPathCommunity
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Into The Box Conference Keynote Day 1 (ITB2025)
Into The Box Conference Keynote Day 1 (ITB2025)Into The Box Conference Keynote Day 1 (ITB2025)
Into The Box Conference Keynote Day 1 (ITB2025)
Ortus Solutions, Corp
 
Web and Graphics Designing Training in Rajpura
Web and Graphics Designing Training in RajpuraWeb and Graphics Designing Training in Rajpura
Web and Graphics Designing Training in Rajpura
Erginous Technology
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 
Mastering Advance Window Functions in SQL.pdf
Mastering Advance Window Functions in SQL.pdfMastering Advance Window Functions in SQL.pdf
Mastering Advance Window Functions in SQL.pdf
Spiral Mantra
 
MINDCTI revenue release Quarter 1 2025 PR
MINDCTI revenue release Quarter 1 2025 PRMINDCTI revenue release Quarter 1 2025 PR
MINDCTI revenue release Quarter 1 2025 PR
MIND CTI
 
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
IEDM 2024 Tutorial2_Advances in CMOS Technologies and Future Directions for C...
organizerofv
 
Semantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AISemantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AI
artmondano
 
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
Transcript: #StandardsGoals for 2025: Standards & certification roundup - Tec...
BookNet Canada
 
Big Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur MorganBig Data Analytics Quick Research Guide by Arthur Morgan
Big Data Analytics Quick Research Guide by Arthur Morgan
Arthur Morgan
 
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager APIUiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPath Community Berlin: Orchestrator API, Swagger, and Test Manager API
UiPathCommunity
 
Social Media App Development Company-EmizenTech
Social Media App Development Company-EmizenTechSocial Media App Development Company-EmizenTech
Social Media App Development Company-EmizenTech
Steve Jonas
 
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdfSAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
SAP Modernization: Maximizing the Value of Your SAP S/4HANA Migration.pdf
Precisely
 
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath MaestroDev Dives: Automate and orchestrate your processes with UiPath Maestro
Dev Dives: Automate and orchestrate your processes with UiPath Maestro
UiPathCommunity
 
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...
Alan Dix
 
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025
BookNet Canada
 
AI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global TrendsAI and Data Privacy in 2025: Global Trends
AI and Data Privacy in 2025: Global Trends
InData Labs
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Into The Box Conference Keynote Day 1 (ITB2025)
Into The Box Conference Keynote Day 1 (ITB2025)Into The Box Conference Keynote Day 1 (ITB2025)
Into The Box Conference Keynote Day 1 (ITB2025)
Ortus Solutions, Corp
 
Web and Graphics Designing Training in Rajpura
Web and Graphics Designing Training in RajpuraWeb and Graphics Designing Training in Rajpura
Web and Graphics Designing Training in Rajpura
Erginous Technology
 
HCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser EnvironmentsHCL Nomad Web – Best Practices and Managing Multiuser Environments
HCL Nomad Web – Best Practices and Managing Multiuser Environments
panagenda
 

Structured Apps with Google Dart

  • 2. AGENDA ► What is Dart? ► How Dart Works ► Dart Features ► Language Tour ► CASE DEMOS ► Questions
  • 3. WHAT IS DART? “...an open-source, batteries-included developer platform for building HTML5 web apps.” dartlang.org
  • 4. BY GOOGLE Gilad Bracha Software Engineer Lars Bak Computer Programmer ► HotSpot VM ► V8 JavaScript Engine ► Dart VM ► Newspeak Language ► Java Language Spec ► Dart Language Spec
  • 5. TYPICAL WEB APP SCENARIO
  • 6. “Hey, I want a web app”
  • 7. “Hey, I want a web app” Backbone.JS
  • 8. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js”
  • 9. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS
  • 10. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery
  • 11. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...”
  • 12. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS
  • 13. “Hey, I want a web app” Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr
  • 14. “Hey, I want a web app” jQueryUI Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr
  • 15. “Hey, I want a web app” jQueryUI Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr Leaflet.JS
  • 16. “Hey, I want a web app” jQueryUI Backbone.JS “Backbone’s only hard dependency is Underscore.js” Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr Leaflet.JS Jasmine BDD
  • 17. “Hey, I want a web app” jQueryUI Backbone.JS “Backbone’s only hard dependency is Underscore.js” Raphael.JS Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr Leaflet.JS Jasmine BDD
  • 18. “Hey, I want a web app” jQueryUI DOCS DOCS DOCS Backbone.JS DOCS “Backbone’s only hard dependency is Underscore.js” Raphael.JS Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr Leaflet.JS Jasmine BDD DOCS DOCS DOCS DOCS DOCS
  • 19. “Hey, I want a web app” jQueryUI DOCS DOCS DOCS Backbone.JS DOCS “Backbone’s only hard dependency is Underscore.js” Raphael.JS Underscore.JS jQuery “For RESTful persistence, history support via Backbone.Router and DOM manipulation with Backbone.View, include jQuery...” Moment.JS Modernizr Leaflet.JS Jasmine BDD DOCS DOCS DOCS DOCS DOCS
  • 20. CONSISTENT AND CLEAR DART SDK Packages MVC Web UI Unit test
  • 21. OFFICIAL ECMA STANDARD ecma-international.org/publications/standards/Ecma-408.htm
  • 22. DART BUNDLE IDE Dartium Dart SDK
  • 23. DART BUNDLE IDE Dartium Dart SDK ► Eclipse-based editor ► Supports code completion, static analysis, Checked/ Production Mode etc… ► Plugins for third-party IDE and Text-Editors
  • 24. DART BUNDLE IDE Dartium Dart SDK ► Eclipse-based editor ► Supports code completion, static analysis, Checked/ Production Mode etc… ► Plugins for third-party IDE and Text-Editors ► Custom build of Chromium with the Dart VM
  • 25. DART BUNDLE IDE Dartium Dart SDK ► Eclipse-based editor ► Supports code completion, static analysis, Checked/ Production Mode etc… ► Plugins for third-party IDE and Text-Editors ► Custom build of Chromium with the Dart VM ► Dart VM, Core Libraries and Command line tools
  • 27. COMMAND LINE TOOLS dart dartanalyzer
  • 28. COMMAND LINE TOOLS dart dartanalyzer docgen
  • 29. COMMAND LINE TOOLS dart dartanalyzer pub docgen
  • 30. COMMAND LINE TOOLS dart dartanalyzer pub docgen dart2js
  • 31. HOW DART WORKS index.dart
  • 32. HOW DART WORKS index.dart Dart Virtual Machine standalone or browser
  • 33. HOW DART WORKS index.dart Dart-to-JavaScript compiler Dart Virtual Machine standalone or browser
  • 34. HOW DART WORKS index.dart Dart Virtual Machine Dart-to-JavaScript compiler standalone or browser index.dart.js
  • 36. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn()
  • 37. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn() imports
  • 38. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn() calls imports
  • 39. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn() calls imports calls
  • 40. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn() calls imports calls dart2js
  • 41. TREE-SHAKING COMPILER Source Application main Library fn() fn() fn() fn() calls imports calls main calls calls fn() fn() dart2js
  • 42. BENCHMARKS dart dart2js js dartlang.org/performance
  • 43. WHO USES DART? dartlang.org/community/who-uses-dart.html
  • 49. ► Object-oriented language ► Single-threaded ► Asynchronous Programming with Futures/Streams ► Concurrency with Isolates ► Lexical Scoping ► Modularity and Scalability
  • 51. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth);! }! ! void main() {! !Person person = new Person(“Joe Bloggs”, 1975);! !print(person.name);! }! !!
  • 52. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth);! }! ! void main() {! !Person person = new Person(“Joe Bloggs”, 1975);! !print(person.name);! }! !! Shorthand Constructors
  • 53. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth);! !Person.withDefaults() : this(‘No name’, 1768);! }! ! void main() {! !Person person = new Person.withDefaults();! !print(person.name);! }! !! Named Constructors
  • 54. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth);! !Person.withDefaults() : this(‘No name’, 1768);! }! ! void main() {! !Person person = new Person.withDefaults();! !print(person.name);! }! !! Initialised defaults
  • 55. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth, {String nationality: ‘unknown’});! !Person.withDefaults() : this(‘No name’, 1768);! }! ! void main() {! !Person person = new Person(“Joe Bloggs”, 1975, nationality: ‘UK’);! !print(person.name);! }! !! Optional named parameters
  • 56. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! !Person.withDefaults() : this(‘No name’, 1768);! }! ! void main() {! !Person person = new Person(“Joe Bloggs”, 1975, ‘UK’);! !print(person.name);! }! !! Optional positional parameters
  • 57. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! !Person.withDefaults() : this(‘No name’, 1768);! !! !Person operator +(Person other) {! ! !return new Person(name + ‘ and ‘ + other.name, 9999);! !}! } !! Operator overrides
  • 58. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! !Person.withDefaults() : this(‘No name’, 1768);! !! !Person operator +(Person other) {! ! !return new Person(name + ‘ and ‘ + other.name, 9999);! !}! ! Shorthand functions !speak() => print(“$name is speaking”);! } !!
  • 59. class Person {! !String name;! !int yearOfBirth;! ! !Person(this.name, this.yearOfBirth, [String nationality = ‘unknown’]);! !Person.withDefaults() : this(‘No name’, 1768);! !! !Person operator +(Person other) {! ! !return new Person(name + ‘ and ‘ + other.name, 9999);! !}! ! !speak() => print(“$name is speaking”);! } !! String interpolation
  • 60. class Person {! !String _name;! !int _yearOfBirth;! ! !Person(this._name, this._yearOfBirth);! !Person.withDefaults() : this(‘No name’, 1768);! ! !Person operator +(Person other) {! ! !return new Person(name + ‘ and ‘ + other.name, 9999);! !}! ! getters and setters !speak() => print(“$_name is speaking”);! ! !String get name => _name;! ! set name(String value) => _name = value;! } !!
  • 62. import “dart:html”;! ! void main() {! !! !InputElement button = new InputElement();! ! ! ! !button.id = “sendButton”;! ! ! ! !button.text = “Donate Bruv!!!”;! ! ! ! !button.classes.add(‘please’);! ! ! ! !button.onClick.listen((e) => print(‘thanks!’));! ! !document.body.children.add(button);! ! ! ! ! ! } !!
  • 63. import “dart:html”;! ! void main() {! !! !InputElement button = new InputElement();! ! ! ! !button.id = “sendButton”;! ! ! ! !button.text = “Donate Bruv!!!”;! ! ! ! !button.classes.add(‘please’);! ! ! ! !button.onClick.listen((e) => print(‘thanks!’));! ! !document.body.children.add(button);! ! ! ! ! ! } !!
  • 64. import “dart:html”;! ! void main() {! !! !InputElement button = new InputElement()! ! ! ! !..id = “sendButton”! ! ! ! !..text = “Donate Bruv!!!”! ! ! ! !..classes.add(‘please’)! ! ! ! !..onClick.listen((e) => print(‘thanks!’));! Method Cascades ! !document.body.children.add(button);! ! ! ! ! ! } !!
  • 65. class Person {! !String name;! !int yearOfBirth;! ! !Person({this.name, this.yearOfBirth});! ! !speak() => print(“$name is speaking”);! }! ! void main() {! !Person person = new Person()! ! ! ! !..name = “Joe Bloggs”! ! ! ! !..yearOfBirth = 1985! ! ! ! !..speak();! ! !print(person.name);! }! !!
  • 67. class Person {! !speak() => print(“person is speaking”);! }! ! class Customer extends Person {! !String _name;! !Customer(this._name);! }! !!
  • 68. class Person {! !speak() => print(“person is speaking”);! }! ! class VIPPermissions extends Person {! !luxuryTreatment() => print(“Your royal suite is ready!”);! }! ! class Customer extends VIPPermissions {! !String _name;! !Customer(this._name);! }! !!
  • 69. class Person {! !speak() => print(“person is speaking”);! }! ! class VIPPermissions extends Person {! !luxuryTreatment() => print(“Your royal suite is ready!”);! }! ! class Customer extends VIPPermissions {! !String _name;! !Customer(this._name);! }! !! Customer IS NOT a VIPPermissions !!!
  • 70. abstract class VIPPermissions {! !luxuryTreatment() => print(“Your royal suite is ready!”);! }! ! class Person {! !speak() => print(“person is speaking”);! }! ! class Customer extends Person with VIPPermissions {! !String _name;! !Customer(this._name);! }! !!
  • 71. abstract class VIPPermissions {! !luxuryTreatment() => print(“Your royal suite is ready!”);! }! ! class Person {! !speak() => print(“person is speaking”);! }! ! class Customer extends Person with VIPPermissions {! !String _name;! !Customer(this._name);! }! ! void main() {! !Customer customer = new Customer(‘Charles’)..luxuryTreatment();! }! !!
  • 72. abstract class VIPPermissions {! !luxuryTreatment() => print(“Your royal suite is ready!”);! }! ! class Person {! !speak() => print(“person is speaking”);! }! ! class Customer extends Person with VIPPermissions {! !String _name;! !Customer(this._name);! }! ! void main() {! !Customer customer = new Customer(‘Charles’)..luxuryTreatment();! }! !!
  • 73. BUT THAT’S NOT ALL! ► Generics ► Mirrors/Reflections ► Transformations ► Metadata/ Annotations ► Factories ► Lazy-loading ► Interoperate with JS ► Observatory ► Automatic Sanitization ► Web Components ► SIMD ► and lots more…
  • 74. JOIN THE DART SIDE ► dartlang.org/codelabs ► api.dartlang.org ► pub.dartlang.org ► @dartlang on Twitter