SlideShare una empresa de Scribd logo
1 de 16
Descargar para leer sin conexión
EISA IN 10 MINUTES

Belleve Invis
ASYNCS


    Means ubobstructive
    Getting important
     – Ajax
     – Resource management
     – Node.js I/O
    Hard to write in pure JavaScript
THREE SEQUENTIAL TASKS IN JAVASCRIPT


 taskA(function(){
     taskB(function(){
         taskC(function(){
             finish()
         })
     })
 })
KEY PROBLEMS


    Nested functions!
     – My screen is narrow
    Hard with loops
    Hard with abstraction
    Code locality is broken
EXAMPLE: TASKS DEFINED IN A LIST, ACT IN ORDER


 var tasks = […];

 var actTasks = function(tasks, deploy){
     var current = 0;
     var act = function(){
         tasks[current]();
         current ++;
         if(tasks[current]) deploy(act)
     }
     deploy(act)
 }

 actTasks(tasks, function(f){ setTimeout(f, 1) });
THAT IN EISA


 var flow = async {
     for var task in tasks:
         wait! 0;
         task()
     end
 }

 flow()
EISA IS


    A new language
     – So, no capacity requirements
    JavaScript targeted
    Designed for interactive developments
     – So, asyncs
ORIGIN: GAME MAKING


    Defining game data – Optimized syntax for DSL
    Game flow – Asyncs
    Large scale RPGs – Module system


    Now is general-use
DEMONSTRATION: 3D SCENE


    http://typeof.net/lab/d2
    Do not focus on the renderer
DEMO IN ACTION


 var loadImage(src, callback):
     ……
     img.onload = function(){ callback img }
     img.src = src
 end
 var loadTextures = async {|callback|
     var texture = getTextureData loadImage! 'images/texture.png'
     ……
     if callback:
         callback { texture: texture, heightMap: heightMap }
     end
 };
MASTER FLOW


 var flow = async {
     ……
     setTextures loadTextures!()
     ……
     gameClock.perk()
     while true:
         renderFrame();
         ……
         gameClock.wait!()
     end
     console.log 'Demo Finished'
 }
HOW ABOUT USING TRADITIONAL WAY?


 var flow = function(){
     loadTextures(textureLoaded)
 }
 var textureLoaded = function(textures){
     ……
     gameClock.perk()
     gameLoop()
 }
 var gameLoop = function(){
     renderFrame();
     gameClock.wait(gameLoop)
 }
TREND


    ECMAScript Harmony
     – Syntax extensions
     – Semantic fixes
    JavaScript-targeted languages
     – From existing languages, e.g. GWT
     – New-created languages, e.g. CoffeeScript
    JavaScript modulation
     – Necessaria – module system in Eisa
FOCUS EISA


    http://github.com/infinte/eisa
    Fork Me!
Q&A


    Belleve Invis
      –   Born in 1992
      –   Now in USTC
      –   be5invis@typeof.net
      –   http://typeof.net
    Eisa
      – Since 2010
      – http://github/infinte/eisa
Thank you
AGO VOBIS GRATIAS

Más contenido relacionado

La actualidad más candente

연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
Jeongkyu Shin
 
System webpack-jspm
System webpack-jspmSystem webpack-jspm
System webpack-jspm
Jesse Warden
 
Node.js and How JavaScript is Changing Server Programming
Node.js and How JavaScript is Changing Server Programming  Node.js and How JavaScript is Changing Server Programming
Node.js and How JavaScript is Changing Server Programming
Tom Croucher
 
Introduction to asynchronous DB access using Node.js and MongoDB
Introduction to asynchronous DB access using Node.js and MongoDBIntroduction to asynchronous DB access using Node.js and MongoDB
Introduction to asynchronous DB access using Node.js and MongoDB
Adrien Joly
 

La actualidad más candente (20)

Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?Introduction to Node.js: What, why and how?
Introduction to Node.js: What, why and how?
 
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
연구자 및 교육자를 위한 계산 및 분석 플랫폼 설계 - PyCon KR 2015
 
Node js
Node jsNode js
Node js
 
Node ppt
Node pptNode ppt
Node ppt
 
About Data::ObjectDriver
About Data::ObjectDriverAbout Data::ObjectDriver
About Data::ObjectDriver
 
Node.js - A Quick Tour
Node.js - A Quick TourNode.js - A Quick Tour
Node.js - A Quick Tour
 
Dmp hadoop getting_start
Dmp hadoop getting_startDmp hadoop getting_start
Dmp hadoop getting_start
 
System webpack-jspm
System webpack-jspmSystem webpack-jspm
System webpack-jspm
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.js
 
Angular2 ecosystem
Angular2 ecosystemAngular2 ecosystem
Angular2 ecosystem
 
Node.js Patterns for Discerning Developers
Node.js Patterns for Discerning DevelopersNode.js Patterns for Discerning Developers
Node.js Patterns for Discerning Developers
 
Nodejs Explained with Examples
Nodejs Explained with ExamplesNodejs Explained with Examples
Nodejs Explained with Examples
 
Node.js
Node.jsNode.js
Node.js
 
The SPDY Protocol
The SPDY ProtocolThe SPDY Protocol
The SPDY Protocol
 
Introduction to node.js
Introduction to node.jsIntroduction to node.js
Introduction to node.js
 
vert.x 소개 및 개발 실습
vert.x 소개 및 개발 실습vert.x 소개 및 개발 실습
vert.x 소개 및 개발 실습
 
Raymond Kuiper - Working the API like a Unix Pro
Raymond Kuiper - Working the API like a Unix ProRaymond Kuiper - Working the API like a Unix Pro
Raymond Kuiper - Working the API like a Unix Pro
 
Node.js and How JavaScript is Changing Server Programming
Node.js and How JavaScript is Changing Server Programming  Node.js and How JavaScript is Changing Server Programming
Node.js and How JavaScript is Changing Server Programming
 
Introduction to asynchronous DB access using Node.js and MongoDB
Introduction to asynchronous DB access using Node.js and MongoDBIntroduction to asynchronous DB access using Node.js and MongoDB
Introduction to asynchronous DB access using Node.js and MongoDB
 
Express js
Express jsExpress js
Express js
 

Destacado

Family Diety (Kuladevata) Dr. Shriniwas Kashalikar
Family Diety (Kuladevata) Dr. Shriniwas KashalikarFamily Diety (Kuladevata) Dr. Shriniwas Kashalikar
Family Diety (Kuladevata) Dr. Shriniwas Kashalikar
shriniwaskashalikar
 
Products I Worked On
Products I Worked OnProducts I Worked On
Products I Worked On
dickt
 
Student recruiting
Student recruitingStudent recruiting
Student recruiting
rizzzwan
 
World Famous Prayer Interpretation By Dr
World  Famous  Prayer  Interpretation By  DrWorld  Famous  Prayer  Interpretation By  Dr
World Famous Prayer Interpretation By Dr
shriniwaskashalikar
 
Zhvillimet dhe parashikimet e ekonomise se kosoves
Zhvillimet dhe parashikimet e ekonomise se kosovesZhvillimet dhe parashikimet e ekonomise se kosoves
Zhvillimet dhe parashikimet e ekonomise se kosoves
Menaxherat
 
Hola me llamo Laura
Hola me llamo  LauraHola me llamo  Laura
Hola me llamo Laura
sbolader
 

Destacado (20)

Teste d2
Teste d2Teste d2
Teste d2
 
R E B I R T H D R
R E B I R T H  D RR E B I R T H  D R
R E B I R T H D R
 
Erp Modus
Erp ModusErp Modus
Erp Modus
 
Webdistilled Social500
Webdistilled Social500Webdistilled Social500
Webdistilled Social500
 
Why Software Publishers are Migrating From Certificates to Activations
Why Software Publishers are Migrating From Certificates to ActivationsWhy Software Publishers are Migrating From Certificates to Activations
Why Software Publishers are Migrating From Certificates to Activations
 
Estate Jewelry Seo Ranking Report
Estate Jewelry Seo Ranking ReportEstate Jewelry Seo Ranking Report
Estate Jewelry Seo Ranking Report
 
P R O B L E M Dr
P R O B L E M  DrP R O B L E M  Dr
P R O B L E M Dr
 
AdminStudio Suite Datasheet
AdminStudio Suite DatasheetAdminStudio Suite Datasheet
AdminStudio Suite Datasheet
 
Family Diety (Kuladevata) Dr. Shriniwas Kashalikar
Family Diety (Kuladevata) Dr. Shriniwas KashalikarFamily Diety (Kuladevata) Dr. Shriniwas Kashalikar
Family Diety (Kuladevata) Dr. Shriniwas Kashalikar
 
Dharma Dr Shriniwas Kashalikar
Dharma Dr Shriniwas KashalikarDharma Dr Shriniwas Kashalikar
Dharma Dr Shriniwas Kashalikar
 
Products I Worked On
Products I Worked OnProducts I Worked On
Products I Worked On
 
Student recruiting
Student recruitingStudent recruiting
Student recruiting
 
SEO, LLC dba Www.Splinternet Marketing.Com Search Engine Rankings On 4-18-2011
SEO, LLC dba Www.Splinternet Marketing.Com Search Engine Rankings On 4-18-2011SEO, LLC dba Www.Splinternet Marketing.Com Search Engine Rankings On 4-18-2011
SEO, LLC dba Www.Splinternet Marketing.Com Search Engine Rankings On 4-18-2011
 
World Famous Prayer Interpretation By Dr
World  Famous  Prayer  Interpretation By  DrWorld  Famous  Prayer  Interpretation By  Dr
World Famous Prayer Interpretation By Dr
 
面向未来的前端类库开发 — KISSY 类库构想与实践
面向未来的前端类库开发  — KISSY 类库构想与实践面向未来的前端类库开发  — KISSY 类库构想与实践
面向未来的前端类库开发 — KISSY 类库构想与实践
 
Zhvillimet dhe parashikimet e ekonomise se kosoves
Zhvillimet dhe parashikimet e ekonomise se kosovesZhvillimet dhe parashikimet e ekonomise se kosoves
Zhvillimet dhe parashikimet e ekonomise se kosoves
 
2010 Software Licensing and Pricing Survey Results and 2011 Predictions
2010 Software Licensing and Pricing Survey Results and 2011 Predictions2010 Software Licensing and Pricing Survey Results and 2011 Predictions
2010 Software Licensing and Pricing Survey Results and 2011 Predictions
 
Hola me llamo Laura
Hola me llamo  LauraHola me llamo  Laura
Hola me llamo Laura
 
Terminating a Construction Contract: Getting it Right
Terminating a Construction Contract: Getting it RightTerminating a Construction Contract: Getting it Right
Terminating a Construction Contract: Getting it Right
 
Rankings blog-news-page-titles
Rankings blog-news-page-titlesRankings blog-news-page-titles
Rankings blog-news-page-titles
 

Similar a D2

The Evolution of Async-Programming on .NET Platform (.Net China, C#)
The Evolution of Async-Programming on .NET Platform (.Net China, C#)The Evolution of Async-Programming on .NET Platform (.Net China, C#)
The Evolution of Async-Programming on .NET Platform (.Net China, C#)
jeffz
 
Threaded Programming
Threaded ProgrammingThreaded Programming
Threaded Programming
Sri Prasanna
 
JavaScript Growing Up
JavaScript Growing UpJavaScript Growing Up
JavaScript Growing Up
David Padbury
 
Jassa la GeekMeet Bucuresti
Jassa la GeekMeet BucurestiJassa la GeekMeet Bucuresti
Jassa la GeekMeet Bucuresti
alexnovac
 

Similar a D2 (20)

Scala
ScalaScala
Scala
 
JS everywhere 2011
JS everywhere 2011JS everywhere 2011
JS everywhere 2011
 
SE 20016 - programming languages landscape.
SE 20016 - programming languages landscape.SE 20016 - programming languages landscape.
SE 20016 - programming languages landscape.
 
Introduction to Scalding and Monoids
Introduction to Scalding and MonoidsIntroduction to Scalding and Monoids
Introduction to Scalding and Monoids
 
MiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScriptMiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScript
 
Play framework
Play frameworkPlay framework
Play framework
 
Scarlet SmallTalk
Scarlet SmallTalkScarlet SmallTalk
Scarlet SmallTalk
 
The Evolution of Async-Programming on .NET Platform (.Net China, C#)
The Evolution of Async-Programming on .NET Platform (.Net China, C#)The Evolution of Async-Programming on .NET Platform (.Net China, C#)
The Evolution of Async-Programming on .NET Platform (.Net China, C#)
 
Emerging Languages: A Tour of the Horizon
Emerging Languages: A Tour of the HorizonEmerging Languages: A Tour of the Horizon
Emerging Languages: A Tour of the Horizon
 
Threaded Programming
Threaded ProgrammingThreaded Programming
Threaded Programming
 
Intro to Scala.js - Scala UG Cologne
Intro to Scala.js - Scala UG CologneIntro to Scala.js - Scala UG Cologne
Intro to Scala.js - Scala UG Cologne
 
Server side JavaScript: going all the way
Server side JavaScript: going all the wayServer side JavaScript: going all the way
Server side JavaScript: going all the way
 
Full Stack Scala
Full Stack ScalaFull Stack Scala
Full Stack Scala
 
JavaScript Growing Up
JavaScript Growing UpJavaScript Growing Up
JavaScript Growing Up
 
Quantifying Container Runtime Performance: OSCON 2017 Open Container Day
Quantifying Container Runtime Performance: OSCON 2017 Open Container DayQuantifying Container Runtime Performance: OSCON 2017 Open Container Day
Quantifying Container Runtime Performance: OSCON 2017 Open Container Day
 
Jassa la GeekMeet Bucuresti
Jassa la GeekMeet BucurestiJassa la GeekMeet Bucuresti
Jassa la GeekMeet Bucuresti
 
OmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMPOmpSs – improving the scalability of OpenMP
OmpSs – improving the scalability of OpenMP
 
wtf is in Java/JDK/wtf7?
wtf is in Java/JDK/wtf7?wtf is in Java/JDK/wtf7?
wtf is in Java/JDK/wtf7?
 
ruby2600 - an Atari 2600 emulator written in Ruby
ruby2600 - an Atari 2600 emulator written in Rubyruby2600 - an Atari 2600 emulator written in Ruby
ruby2600 - an Atari 2600 emulator written in Ruby
 
Exactly once with spark streaming
Exactly once with spark streamingExactly once with spark streaming
Exactly once with spark streaming
 

Más de taobao.com

编辑器设计U editor
编辑器设计U editor编辑器设计U editor
编辑器设计U editor
taobao.com
 
淘宝开放产品前端实践
淘宝开放产品前端实践淘宝开放产品前端实践
淘宝开放产品前端实践
taobao.com
 
广告投放代码和创意代码持续优化
广告投放代码和创意代码持续优化广告投放代码和创意代码持续优化
广告投放代码和创意代码持续优化
taobao.com
 
第三方内容开发最佳实践
第三方内容开发最佳实践第三方内容开发最佳实践
第三方内容开发最佳实践
taobao.com
 
编辑器设计Kissy editor
编辑器设计Kissy editor编辑器设计Kissy editor
编辑器设计Kissy editor
taobao.com
 
百度前端性能监控与优化实践
百度前端性能监控与优化实践百度前端性能监控与优化实践
百度前端性能监控与优化实践
taobao.com
 
Node.js在淘宝的应用实践
Node.js在淘宝的应用实践Node.js在淘宝的应用实践
Node.js在淘宝的应用实践
taobao.com
 
Kind editor设计思路
Kind editor设计思路Kind editor设计思路
Kind editor设计思路
taobao.com
 
Java script physical engine
Java script physical engineJava script physical engine
Java script physical engine
taobao.com
 
Html5环保小游戏
Html5环保小游戏Html5环保小游戏
Html5环保小游戏
taobao.com
 
阅读类Web应用前端技术探索
阅读类Web应用前端技术探索阅读类Web应用前端技术探索
阅读类Web应用前端技术探索
taobao.com
 
完颜:移动网站的兼容性探索
完颜:移动网站的兼容性探索完颜:移动网站的兼容性探索
完颜:移动网站的兼容性探索
taobao.com
 
张平:JavaScript引擎实现
张平:JavaScript引擎实现张平:JavaScript引擎实现
张平:JavaScript引擎实现
taobao.com
 
高力:19楼现有前端架构
高力:19楼现有前端架构高力:19楼现有前端架构
高力:19楼现有前端架构
taobao.com
 
李成银:前端编译平台
李成银:前端编译平台李成银:前端编译平台
李成银:前端编译平台
taobao.com
 
钱宝坤:多浏览器集成的JavaScript单元测试工具
钱宝坤:多浏览器集成的JavaScript单元测试工具钱宝坤:多浏览器集成的JavaScript单元测试工具
钱宝坤:多浏览器集成的JavaScript单元测试工具
taobao.com
 
张克军:前端基础架构的实践和思考
张克军:前端基础架构的实践和思考张克军:前端基础架构的实践和思考
张克军:前端基础架构的实践和思考
taobao.com
 
刘平川:【用户行为分析】Marmot实践
刘平川:【用户行为分析】Marmot实践刘平川:【用户行为分析】Marmot实践
刘平川:【用户行为分析】Marmot实践
taobao.com
 
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
taobao.com
 

Más de taobao.com (20)

编辑器设计U editor
编辑器设计U editor编辑器设计U editor
编辑器设计U editor
 
Berserk js
Berserk jsBerserk js
Berserk js
 
淘宝开放产品前端实践
淘宝开放产品前端实践淘宝开放产品前端实践
淘宝开放产品前端实践
 
广告投放代码和创意代码持续优化
广告投放代码和创意代码持续优化广告投放代码和创意代码持续优化
广告投放代码和创意代码持续优化
 
第三方内容开发最佳实践
第三方内容开发最佳实践第三方内容开发最佳实践
第三方内容开发最佳实践
 
编辑器设计Kissy editor
编辑器设计Kissy editor编辑器设计Kissy editor
编辑器设计Kissy editor
 
百度前端性能监控与优化实践
百度前端性能监控与优化实践百度前端性能监控与优化实践
百度前端性能监控与优化实践
 
Node.js在淘宝的应用实践
Node.js在淘宝的应用实践Node.js在淘宝的应用实践
Node.js在淘宝的应用实践
 
Kind editor设计思路
Kind editor设计思路Kind editor设计思路
Kind editor设计思路
 
Java script physical engine
Java script physical engineJava script physical engine
Java script physical engine
 
Html5环保小游戏
Html5环保小游戏Html5环保小游戏
Html5环保小游戏
 
阅读类Web应用前端技术探索
阅读类Web应用前端技术探索阅读类Web应用前端技术探索
阅读类Web应用前端技术探索
 
完颜:移动网站的兼容性探索
完颜:移动网站的兼容性探索完颜:移动网站的兼容性探索
完颜:移动网站的兼容性探索
 
张平:JavaScript引擎实现
张平:JavaScript引擎实现张平:JavaScript引擎实现
张平:JavaScript引擎实现
 
高力:19楼现有前端架构
高力:19楼现有前端架构高力:19楼现有前端架构
高力:19楼现有前端架构
 
李成银:前端编译平台
李成银:前端编译平台李成银:前端编译平台
李成银:前端编译平台
 
钱宝坤:多浏览器集成的JavaScript单元测试工具
钱宝坤:多浏览器集成的JavaScript单元测试工具钱宝坤:多浏览器集成的JavaScript单元测试工具
钱宝坤:多浏览器集成的JavaScript单元测试工具
 
张克军:前端基础架构的实践和思考
张克军:前端基础架构的实践和思考张克军:前端基础架构的实践和思考
张克军:前端基础架构的实践和思考
 
刘平川:【用户行为分析】Marmot实践
刘平川:【用户行为分析】Marmot实践刘平川:【用户行为分析】Marmot实践
刘平川:【用户行为分析】Marmot实践
 
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
吴英杰:【用户行为分析】淘宝页面显微镜系统原理及实践
 

Último

Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 

Último (20)

Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 

D2

  • 1. EISA IN 10 MINUTES Belleve Invis
  • 2. ASYNCS  Means ubobstructive  Getting important – Ajax – Resource management – Node.js I/O  Hard to write in pure JavaScript
  • 3. THREE SEQUENTIAL TASKS IN JAVASCRIPT taskA(function(){ taskB(function(){ taskC(function(){ finish() }) }) })
  • 4. KEY PROBLEMS  Nested functions! – My screen is narrow  Hard with loops  Hard with abstraction  Code locality is broken
  • 5. EXAMPLE: TASKS DEFINED IN A LIST, ACT IN ORDER var tasks = […]; var actTasks = function(tasks, deploy){ var current = 0; var act = function(){ tasks[current](); current ++; if(tasks[current]) deploy(act) } deploy(act) } actTasks(tasks, function(f){ setTimeout(f, 1) });
  • 6. THAT IN EISA var flow = async { for var task in tasks: wait! 0; task() end } flow()
  • 7. EISA IS  A new language – So, no capacity requirements  JavaScript targeted  Designed for interactive developments – So, asyncs
  • 8. ORIGIN: GAME MAKING  Defining game data – Optimized syntax for DSL  Game flow – Asyncs  Large scale RPGs – Module system  Now is general-use
  • 9. DEMONSTRATION: 3D SCENE  http://typeof.net/lab/d2  Do not focus on the renderer
  • 10. DEMO IN ACTION var loadImage(src, callback): …… img.onload = function(){ callback img } img.src = src end var loadTextures = async {|callback| var texture = getTextureData loadImage! 'images/texture.png' …… if callback: callback { texture: texture, heightMap: heightMap } end };
  • 11. MASTER FLOW var flow = async { …… setTextures loadTextures!() …… gameClock.perk() while true: renderFrame(); …… gameClock.wait!() end console.log 'Demo Finished' }
  • 12. HOW ABOUT USING TRADITIONAL WAY? var flow = function(){ loadTextures(textureLoaded) } var textureLoaded = function(textures){ …… gameClock.perk() gameLoop() } var gameLoop = function(){ renderFrame(); gameClock.wait(gameLoop) }
  • 13. TREND  ECMAScript Harmony – Syntax extensions – Semantic fixes  JavaScript-targeted languages – From existing languages, e.g. GWT – New-created languages, e.g. CoffeeScript  JavaScript modulation – Necessaria – module system in Eisa
  • 14. FOCUS EISA  http://github.com/infinte/eisa  Fork Me!
  • 15. Q&A  Belleve Invis – Born in 1992 – Now in USTC – be5invis@typeof.net – http://typeof.net  Eisa – Since 2010 – http://github/infinte/eisa