SlideShare uma empresa Scribd logo
1 de 13
Baixar para ler offline
S01E02

CoffeeScript
写更少的代码,做更多的事

云谦, 20120802
chenchengpro @ weibo & twitter




                                 TMB 剧组出品
Coffee 初印象


• Coffee 是⼀一⻔门 JavaScript 预编译语⾔言
• Coffee 仅仅是 JavaScript
• Coffee 是 JavaScript 的精华部分
It’s Just JavaScript

KISSY.ready(function(S) {

  S.all(“body”).html(“hello world”);

});
It’s Just JavaScript

KISSY.ready (S) ->

  S.all(“body”).html “hello world”
Coffee 初印象


• Coffee 是⼀一⻔门 JavaScript 预编译语⾔言
• Coffee 仅仅是 JavaScript
• Coffee 是 JavaScript 的精华部分
•   环境
•   DEMO
•   感受
安装
NodeJS:
http://nodejs.org/
brew install nodejs (mac)

Coffee:
npm install -g coffee-script
编译
命令⾏行:
coffee -c test.coffee
coffee -wc test.coffee

⼯工具:
cafe, grunt
codekit, livereload, ...
DEMO
感受
• 写更少的代码,做更多的事
• 兼容
• 性能
• 调试
• 协作
• 缺点
预告
• S01E03 —— Sass, Less 等 CSS 预编译语⾔言
   的介绍及如何选择
• S01E04 —— NodeJS 全堆栈实践
• S01E05 —— Jasmine ⾼高级⽤用法
• S01E06 —— Coffee + Jade + Sass,淘宝⾸首
   ⻚页改版实践
• ...
Thanks!

Mais conteúdo relacionado

Destaque

Do You Framework.s01.e02.kissy dpl 设计
Do You Framework.s01.e02.kissy dpl 设计Do You Framework.s01.e02.kissy dpl 设计
Do You Framework.s01.e02.kissy dpl 设计
lanlancamp
 

Destaque (8)

Lie to me S01.e02.反馈体验
Lie to me S01.e02.反馈体验Lie to me S01.e02.反馈体验
Lie to me S01.e02.反馈体验
 
Lie to me S01.e01.黄金矿工
Lie to me S01.e01.黄金矿工Lie to me S01.e01.黄金矿工
Lie to me S01.e01.黄金矿工
 
20100915 學習撰寫 Google Chrome Extension
20100915 學習撰寫 Google Chrome Extension20100915 學習撰寫 Google Chrome Extension
20100915 學習撰寫 Google Chrome Extension
 
lie to me.s1.e3-数据源头那些事
lie to me.s1.e3-数据源头那些事lie to me.s1.e3-数据源头那些事
lie to me.s1.e3-数据源头那些事
 
Do You Framework.s01.e02.kissy dpl 设计
Do You Framework.s01.e02.kissy dpl 设计Do You Framework.s01.e02.kissy dpl 设计
Do You Framework.s01.e02.kissy dpl 设计
 
CoffeeScript
CoffeeScriptCoffeeScript
CoffeeScript
 
The Six Highest Performing B2B Blog Post Formats
The Six Highest Performing B2B Blog Post FormatsThe Six Highest Performing B2B Blog Post Formats
The Six Highest Performing B2B Blog Post Formats
 
The Outcome Economy
The Outcome EconomyThe Outcome Economy
The Outcome Economy
 

Semelhante a 再见侏罗纪.S01.e02.CoffeeScript

A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
Wen-Tien Chang
 
2012 java two-desktop-appliction-using-j-ruby-with-swt
2012 java two-desktop-appliction-using-j-ruby-with-swt2012 java two-desktop-appliction-using-j-ruby-with-swt
2012 java two-desktop-appliction-using-j-ruby-with-swt
tka
 
打造你的工具人 Chatbot / Voice Assistant Development 101
打造你的工具人 Chatbot / Voice Assistant Development 101打造你的工具人 Chatbot / Voice Assistant Development 101
打造你的工具人 Chatbot / Voice Assistant Development 101
Ryan Chung
 

Semelhante a 再见侏罗纪.S01.e02.CoffeeScript (20)

美团点评技术沙龙05 - 前后端联调方案探索与应用
美团点评技术沙龙05 - 前后端联调方案探索与应用美团点评技术沙龙05 - 前后端联调方案探索与应用
美团点评技术沙龙05 - 前后端联调方案探索与应用
 
A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
A brief introduction to Vagrant – 原來 VirtualBox 可以這樣玩
 
2012 java two-desktop-appliction-using-j-ruby-with-swt
2012 java two-desktop-appliction-using-j-ruby-with-swt2012 java two-desktop-appliction-using-j-ruby-with-swt
2012 java two-desktop-appliction-using-j-ruby-with-swt
 
Node.js 進攻桌面開發
Node.js 進攻桌面開發Node.js 進攻桌面開發
Node.js 進攻桌面開發
 
凌波微步:wagon + VS Code 的輕功哲學
凌波微步:wagon + VS Code 的輕功哲學凌波微步:wagon + VS Code 的輕功哲學
凌波微步:wagon + VS Code 的輕功哲學
 
从无阻塞并行脚本加载(Lab.js)到浏览器消息模型
从无阻塞并行脚本加载(Lab.js)到浏览器消息模型从无阻塞并行脚本加载(Lab.js)到浏览器消息模型
从无阻塞并行脚本加载(Lab.js)到浏览器消息模型
 
不會 Javascript 沒關係,用 Blazor 來解決前端需求 - 成為 Full Stack .NET 開發者吧 - .NET Conf 2020...
不會 Javascript 沒關係,用 Blazor 來解決前端需求 - 成為 Full Stack .NET 開發者吧 - .NET Conf 2020...不會 Javascript 沒關係,用 Blazor 來解決前端需求 - 成為 Full Stack .NET 開發者吧 - .NET Conf 2020...
不會 Javascript 沒關係,用 Blazor 來解決前端需求 - 成為 Full Stack .NET 開發者吧 - .NET Conf 2020...
 
.Net网络编程入门
.Net网络编程入门.Net网络编程入门
.Net网络编程入门
 
從頭打造 C#、.NET 與 ASP.NET Core 開發環境
從頭打造 C#、.NET 與 ASP.NET Core 開發環境從頭打造 C#、.NET 與 ASP.NET Core 開發環境
從頭打造 C#、.NET 與 ASP.NET Core 開發環境
 
Open source的devops工具箱 公開版@coscup2016
Open source的devops工具箱 公開版@coscup2016Open source的devops工具箱 公開版@coscup2016
Open source的devops工具箱 公開版@coscup2016
 
Blazor in NET 8 的重大改變___________________
Blazor in NET 8 的重大改變___________________Blazor in NET 8 的重大改變___________________
Blazor in NET 8 的重大改變___________________
 
從軟體開發角度
談 Docker 的應用
從軟體開發角度
談 Docker 的應用從軟體開發角度
談 Docker 的應用
從軟體開發角度
談 Docker 的應用
 
JSDC 2015 React-Native 實戰
JSDC 2015 React-Native 實戰JSDC 2015 React-Native 實戰
JSDC 2015 React-Native 實戰
 
twMVC#42 Azure DevOps Service Pipeline設計與非正常應用
twMVC#42 Azure DevOps Service Pipeline設計與非正常應用twMVC#42 Azure DevOps Service Pipeline設計與非正常應用
twMVC#42 Azure DevOps Service Pipeline設計與非正常應用
 
Study4 love.2016.2.20.ionic
Study4 love.2016.2.20.ionicStudy4 love.2016.2.20.ionic
Study4 love.2016.2.20.ionic
 
Pegasus: Designing a Distributed Key Value System (Arch summit beijing-2016)
Pegasus: Designing a Distributed Key Value System (Arch summit beijing-2016)Pegasus: Designing a Distributed Key Value System (Arch summit beijing-2016)
Pegasus: Designing a Distributed Key Value System (Arch summit beijing-2016)
 
面對移動化App挑戰的架構設計
面對移動化App挑戰的架構設計面對移動化App挑戰的架構設計
面對移動化App挑戰的架構設計
 
一個微信專案從0到000的效能調教
一個微信專案從0到000的效能調教一個微信專案從0到000的效能調教
一個微信專案從0到000的效能調教
 
打造你的工具人 Chatbot / Voice Assistant Development 101
打造你的工具人 Chatbot / Voice Assistant Development 101打造你的工具人 Chatbot / Voice Assistant Development 101
打造你的工具人 Chatbot / Voice Assistant Development 101
 
Non-MVC Web Framework
Non-MVC Web FrameworkNon-MVC Web Framework
Non-MVC Web Framework
 

Último

IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
schonejummy
 
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVCHi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
schonejummy
 
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
daisycvs
 
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
ramacollinz
 
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
fionamali24
 
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
ramacollinz
 
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
schonejummy
 
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
fionamali24
 
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
zuhaibhaideri99
 
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
cytotecshop6
 
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
daisycvs
 
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
schonejummy
 

Último (14)

IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
IN Port Alfred [[[[WhatsApp (((+27632505360))) *____**)) ABORTION PILLS FOR S...
 
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVCHi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
Hi 00971552965071 ABORTION PILLS IN Marina Palm Jumeirah JVC
 
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
Abortion Pills for sale in Ajman (UAE) ((+27.7377;58;557) Abortion Pills / Cy...
 
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
ABORTION PILLS IN BADPLAAS [(+27632505360 BUY CYTOTEC PILLS IN BADPLAAS/ABORT...
 
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
Abortion in AL AIN*%UAE^*[☎️+971523788684**]]@ @# Abortion pills for sale in ...
 
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
Secunda +27<~>0632505360 Abortion Pills Around Embalenhle Approved Safe 4 Ter...
 
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
Al Doha +971552965071 Abortion Pills in Doha Qatar Al Wakrah misoprostol/cyto...
 
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
Kuwait City₩Kit【+971523788684】彡 ௹#Abortion Pills For sale In Kuwait City.
 
《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》
《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》
《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》《段永平(投資的本質)》
 
cs代写服务如何收费?坚持高性价比的服务宗旨 ,满足更多留学生的CS作业代写需求,为大家提供最合理的代写价格。
cs代写服务如何收费?坚持高性价比的服务宗旨 ,满足更多留学生的CS作业代写需求,为大家提供最合理的代写价格。cs代写服务如何收费?坚持高性价比的服务宗旨 ,满足更多留学生的CS作业代写需求,为大家提供最合理的代写价格。
cs代写服务如何收费?坚持高性价比的服务宗旨 ,满足更多留学生的CS作业代写需求,为大家提供最合理的代写价格。
 
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
IN MUSCAT & OMAN 🏥[^(+968_76875161*))☎️)¥) LEGIT Cytotec Pills.
 
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
ABORTION PILLS IN AL WAKRAH《@௵+971523788684௵》CYTOTEC TABLETS FOR SALE IN DOHA...
 
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
Where to buy(^^+27737758557** Abortion Pills in Dubai/UAE/ Abudhabi/Fujairah ...
 
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
Bulawayo +27632505360 Abortion Pills in Bulawayo Harare Cytotec/Misoprostol i...
 

再见侏罗纪.S01.e02.CoffeeScript