SlideShare ist ein Scribd-Unternehmen logo
1 von 18
Downloaden Sie, um offline zu lesen
TYPESCRIPT 
DUUG 25 SEPTEMBER 2014 
4F
)F1)F '1**-/FžF F3+ -/F¥F´%)1# '1**-/
TYPESCRIPT LETS YOU WRITE JAVASCRIPT 
THE WAY YOU REALLY WANT TO.
TYPESCRIPT 
4+ . 
	)/ -! . 
'.. . 

*0' . 
0)/$*). 
 ) -$.
JAVASCRIPT 
TYPESCRIPT IS A TYPED SUPERSET OF JAVASCRIPT THAT COMPILES TO PLAIN JAVASCRIPT.
BENEFITS 
*(+$' - 
4+ F.! /4 
0/*F*(+' /$*) 
 '-/$*)F!$' .F¨ F
$)F 
© 
 
)0'-‡%.F )
TYPES 
/-$) 
0( - 
**' ) 
--4 
)0( 
)4 
*$
STRING / NUMBER / BOOLEAN 
var name: string = 'Jan'; 
var age: number = 24; 
var isDutch: boolean = true; 
name = isDutch; 
))*/F*)1 -/FÞ**' )ÞF/*FÞ./-$)Þ‡
ARRAY 
var list: number[] = [1, 2, 3]; 
list.push(4); 
list.push('five'); 
*0'F)*/F++'4F/4+ FÞ)0( -ÞF/*F-0( )/FtF2#$#F$.F*!F/4+ FÞ./-$)Þ‡
ENUM 
enum Countries { 'Netherlands', 'Belgium', 'Unkown' } 
var country: Countries = Countries.Netherlands;
ANY 
var notSure: any = 4; 
notSure = maybe a string instead; 
notSure = false; // okay, definitely a boolean
INTERFACES 
interface IPerson { 
Name: string; 
Country: Countries; 
IsDutch: boolean; 
callName(): string; 
}
INTERFACES 
class person implements IPerson { 
} 
'..F+ -.*)F '- .F$)/ -! F	 -.*)F0/F* .F)*/F$(+' ( )/F$/‰ 
4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ( ÞF!-*(F/4+ FÞ	 -.*)Þ‡ 
4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ*0)/$ .ÞF!-*(F/4+ FÞ	 -.*)Þ‡ 
4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ	.0/#ÞF!-*(F/4+ FÞ	 -.*)Þ‡ 
4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ''( ÞF!-*(F/4+ FÞ	 -.*)Þ‡
CLASSES 
class person implements IPerson { 
public Name: string; 
public Country: Countries; 
public IsDutch: boolean; 
constructor(name: string, country: Countries, isDutch: boolean) { 
this.Name = name; 
this.Country = Countries.Netherlands; 
this.IsDutch = isDutch; 
} 
callName() { 
return this.Name; 
} 
}
CLASSES - A SHORTER WAY 
class person implements IPerson { 
constructor(public Name: string, public Country: Countries, 
public IsDutch: boolean) { } 
callName() { 
return this.Name; 
} 
}
NEW CLASS 
var dave = new person('Dave Woestenborghs', Countries.Belgium, false);
GENERICS 
function identityT(arg: T): T { 
return arg; 
} 
var output = this.identitystring('one'); 
var output = this.identitystring(1); 
0++'$ F+-( / -.F*F)*/F(/#F)4F.$)/0- F*!F''F/- /‰ 
*0'F)*/F++'4F/4+ FÞ./-$)ÞF/*F-0( )/FtF2#$#F$.F*!F/4+ FÞ)0( -Þ‡
TOOLS 
$.0'F/0$*FustvF0+/ Fu 
$.0'F/0$*FustuF¨ F

Weitere ähnliche Inhalte

Was ist angesagt? (12)

Algoritmo divisao
Algoritmo divisaoAlgoritmo divisao
Algoritmo divisao
 
Seasion7
Seasion7Seasion7
Seasion7
 
Somerville, Ma Arts at the Armory building inaccessible- state complaint Mar...
Somerville, Ma Arts at the Armory building inaccessible-  state complaint Mar...Somerville, Ma Arts at the Armory building inaccessible-  state complaint Mar...
Somerville, Ma Arts at the Armory building inaccessible- state complaint Mar...
 
Webinar: Online Fundraising
Webinar: Online FundraisingWebinar: Online Fundraising
Webinar: Online Fundraising
 
clase visual basic
clase visual basicclase visual basic
clase visual basic
 
Design thinking ideate - KAbbott
Design thinking ideate - KAbbottDesign thinking ideate - KAbbott
Design thinking ideate - KAbbott
 
RACC -Comparativa Bicis Publicas full_v120625_def
RACC -Comparativa Bicis Publicas full_v120625_defRACC -Comparativa Bicis Publicas full_v120625_def
RACC -Comparativa Bicis Publicas full_v120625_def
 
Anna bhaaryato
Anna bhaaryatoAnna bhaaryato
Anna bhaaryato
 
ABAP EVENTS EXAMPLE
ABAP EVENTS EXAMPLEABAP EVENTS EXAMPLE
ABAP EVENTS EXAMPLE
 
หนึ่งใจให้ธรรมะ
หนึ่งใจให้ธรรมะหนึ่งใจให้ธรรมะ
หนึ่งใจให้ธรรมะ
 
mlitt
mlittmlitt
mlitt
 
Using MySQL in a web-scale environment
Using MySQL in a web-scale environmentUsing MySQL in a web-scale environment
Using MySQL in a web-scale environment
 

Ähnlich wie DUUG meetup Colours - Typescript

DUUG meetup Colours - Custom sections v6 vs v7
DUUG meetup Colours - Custom sections v6 vs v7DUUG meetup Colours - Custom sections v6 vs v7
DUUG meetup Colours - Custom sections v6 vs v7Colours B.V.
 
12.19 EHS Class of 1990
12.19 EHS Class of 199012.19 EHS Class of 1990
12.19 EHS Class of 1990Nicodemas_1996
 
59598225 thesis-slim
59598225 thesis-slim59598225 thesis-slim
59598225 thesis-slimThanh Nguyen
 
Museum Collections Management and Online Exhibit Software
Museum Collections Management and Online Exhibit SoftwareMuseum Collections Management and Online Exhibit Software
Museum Collections Management and Online Exhibit SoftwareK L
 
"Innovación radical: open access, auto-aprendizaje y sobreabundancia"
"Innovación radical: open access, auto-aprendizaje y sobreabundancia""Innovación radical: open access, auto-aprendizaje y sobreabundancia"
"Innovación radical: open access, auto-aprendizaje y sobreabundancia"@cristobalcobo
 
ulF.Jftrbqlr-lrnlJ.}r{FFF.docx
ulF.Jftrbqlr-lrnlJ.}r{FFF.docxulF.Jftrbqlr-lrnlJ.}r{FFF.docx
ulF.Jftrbqlr-lrnlJ.}r{FFF.docxmarilucorr
 
uttaradhikar-1
uttaradhikar-1uttaradhikar-1
uttaradhikar-1Mainu4
 
3 narashasns aur antim avtar
3 narashasns aur antim avtar3 narashasns aur antim avtar
3 narashasns aur antim avtaryusmohd1
 
"Financing, Energy Projects and Infrastructure"
"Financing, Energy Projects and Infrastructure""Financing, Energy Projects and Infrastructure"
"Financing, Energy Projects and Infrastructure"Cynthia Thyfault
 
GPME - Administração e análise de custos
GPME - Administração e análise de custosGPME - Administração e análise de custos
GPME - Administração e análise de custosRicardo Barboza da Silva
 
Janusz Korczak - wykaz książek i artykułów w zbiorach BP Cieszyn
Janusz Korczak - wykaz książek i artykułów w zbiorach BP CieszynJanusz Korczak - wykaz książek i artykułów w zbiorach BP Cieszyn
Janusz Korczak - wykaz książek i artykułów w zbiorach BP CieszynMultimedia Lab - Pedagogical Library
 
5 islaam ke paigambar muhammad(saw)
5 islaam ke paigambar muhammad(saw)5 islaam ke paigambar muhammad(saw)
5 islaam ke paigambar muhammad(saw)yusmohd1
 
anddolon-8
anddolon-8anddolon-8
anddolon-8Mainu4
 

Ähnlich wie DUUG meetup Colours - Typescript (19)

DUUG meetup Colours - Custom sections v6 vs v7
DUUG meetup Colours - Custom sections v6 vs v7DUUG meetup Colours - Custom sections v6 vs v7
DUUG meetup Colours - Custom sections v6 vs v7
 
pdf-road-map.pptx
pdf-road-map.pptxpdf-road-map.pptx
pdf-road-map.pptx
 
12.19 EHS Class of 1990
12.19 EHS Class of 199012.19 EHS Class of 1990
12.19 EHS Class of 1990
 
T&H Credentials_May 23 (2).pdf
T&H Credentials_May 23 (2).pdfT&H Credentials_May 23 (2).pdf
T&H Credentials_May 23 (2).pdf
 
Ismayilo vv russia-echrjudgment_eng.pdf
Ismayilo vv russia-echrjudgment_eng.pdfIsmayilo vv russia-echrjudgment_eng.pdf
Ismayilo vv russia-echrjudgment_eng.pdf
 
59598225 thesis-slim
59598225 thesis-slim59598225 thesis-slim
59598225 thesis-slim
 
Museum Collections Management and Online Exhibit Software
Museum Collections Management and Online Exhibit SoftwareMuseum Collections Management and Online Exhibit Software
Museum Collections Management and Online Exhibit Software
 
"Innovación radical: open access, auto-aprendizaje y sobreabundancia"
"Innovación radical: open access, auto-aprendizaje y sobreabundancia""Innovación radical: open access, auto-aprendizaje y sobreabundancia"
"Innovación radical: open access, auto-aprendizaje y sobreabundancia"
 
ulF.Jftrbqlr-lrnlJ.}r{FFF.docx
ulF.Jftrbqlr-lrnlJ.}r{FFF.docxulF.Jftrbqlr-lrnlJ.}r{FFF.docx
ulF.Jftrbqlr-lrnlJ.}r{FFF.docx
 
Vampiro -a_mascara_-_compendi
Vampiro  -a_mascara_-_compendiVampiro  -a_mascara_-_compendi
Vampiro -a_mascara_-_compendi
 
uttaradhikar-1
uttaradhikar-1uttaradhikar-1
uttaradhikar-1
 
Faster develoment with CakePHP 3
Faster develoment with CakePHP 3Faster develoment with CakePHP 3
Faster develoment with CakePHP 3
 
3 narashasns aur antim avtar
3 narashasns aur antim avtar3 narashasns aur antim avtar
3 narashasns aur antim avtar
 
"Financing, Energy Projects and Infrastructure"
"Financing, Energy Projects and Infrastructure""Financing, Energy Projects and Infrastructure"
"Financing, Energy Projects and Infrastructure"
 
GPME - Administração e análise de custos
GPME - Administração e análise de custosGPME - Administração e análise de custos
GPME - Administração e análise de custos
 
Janusz Korczak - wykaz książek i artykułów w zbiorach BP Cieszyn
Janusz Korczak - wykaz książek i artykułów w zbiorach BP CieszynJanusz Korczak - wykaz książek i artykułów w zbiorach BP Cieszyn
Janusz Korczak - wykaz książek i artykułów w zbiorach BP Cieszyn
 
5 islaam ke paigambar muhammad(saw)
5 islaam ke paigambar muhammad(saw)5 islaam ke paigambar muhammad(saw)
5 islaam ke paigambar muhammad(saw)
 
Ameleth
AmelethAmeleth
Ameleth
 
anddolon-8
anddolon-8anddolon-8
anddolon-8
 

Mehr von Colours B.V.

How-To Sessies: Customer Journeys
How-To Sessies: Customer JourneysHow-To Sessies: Customer Journeys
How-To Sessies: Customer JourneysColours B.V.
 
Webinar - Predicting visitor behavior
Webinar - Predicting visitor behaviorWebinar - Predicting visitor behavior
Webinar - Predicting visitor behaviorColours B.V.
 
SUGNL Colours - Otap & content delivery
SUGNL Colours - Otap & content deliverySUGNL Colours - Otap & content delivery
SUGNL Colours - Otap & content deliveryColours B.V.
 
SUGNL Colours - Dms developer vs marketeer
SUGNL Colours - Dms developer vs marketeerSUGNL Colours - Dms developer vs marketeer
SUGNL Colours - Dms developer vs marketeerColours B.V.
 
SUGNL Colours - Git & branching
SUGNL Colours - Git & branchingSUGNL Colours - Git & branching
SUGNL Colours - Git & branchingColours B.V.
 
Online trends | Gebruikerservaring (Whatsup 12/9/13)
Online trends | Gebruikerservaring (Whatsup 12/9/13)Online trends | Gebruikerservaring (Whatsup 12/9/13)
Online trends | Gebruikerservaring (Whatsup 12/9/13)Colours B.V.
 
Van een op een, naar veel - Seminar Web, apps, email
Van een op een, naar veel - Seminar Web, apps, emailVan een op een, naar veel - Seminar Web, apps, email
Van een op een, naar veel - Seminar Web, apps, emailColours B.V.
 
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?Colours B.V.
 
Ideale ontwikkelaanpak - Seminar Web, apps, email
Ideale ontwikkelaanpak - Seminar Web, apps, emailIdeale ontwikkelaanpak - Seminar Web, apps, email
Ideale ontwikkelaanpak - Seminar Web, apps, emailColours B.V.
 
Multichannel - Seminar Web, apps,email
Multichannel - Seminar Web, apps,emailMultichannel - Seminar Web, apps,email
Multichannel - Seminar Web, apps,emailColours B.V.
 
Case euromaster - colours voor Dutch Interactive Awards
Case euromaster - colours voor Dutch Interactive AwardsCase euromaster - colours voor Dutch Interactive Awards
Case euromaster - colours voor Dutch Interactive AwardsColours B.V.
 
Wat is drupal? - Drupal seminar 20 mei 2010, Colours
Wat is drupal? - Drupal seminar 20 mei 2010, ColoursWat is drupal? - Drupal seminar 20 mei 2010, Colours
Wat is drupal? - Drupal seminar 20 mei 2010, ColoursColours B.V.
 
Drupal in 5 vragen - Drupal seminar 20 mei 2010, Colours
Drupal in 5 vragen - Drupal seminar 20 mei 2010, ColoursDrupal in 5 vragen - Drupal seminar 20 mei 2010, Colours
Drupal in 5 vragen - Drupal seminar 20 mei 2010, ColoursColours B.V.
 
Drupal & ISES, Drupal seminar 20 mei 2010, Colours
Drupal & ISES, Drupal seminar 20 mei 2010, ColoursDrupal & ISES, Drupal seminar 20 mei 2010, Colours
Drupal & ISES, Drupal seminar 20 mei 2010, ColoursColours B.V.
 
Charlotte van dael DDMA Ilounge 9maart2010
Charlotte van dael DDMA Ilounge 9maart2010Charlotte van dael DDMA Ilounge 9maart2010
Charlotte van dael DDMA Ilounge 9maart2010Colours B.V.
 
Hyves @ #Socialsucces 2 december 2009
Hyves @ #Socialsucces 2 december 2009Hyves @ #Socialsucces 2 december 2009
Hyves @ #Socialsucces 2 december 2009Colours B.V.
 
Usability - Seminar Steeds Betere Website 24 nov 2009
Usability - Seminar Steeds Betere Website 24 nov 2009Usability - Seminar Steeds Betere Website 24 nov 2009
Usability - Seminar Steeds Betere Website 24 nov 2009Colours B.V.
 
Verder Magazine van LECTRIC Groep
Verder Magazine van LECTRIC GroepVerder Magazine van LECTRIC Groep
Verder Magazine van LECTRIC GroepColours B.V.
 
Colours Bureaupresentatie
Colours BureaupresentatieColours Bureaupresentatie
Colours BureaupresentatieColours B.V.
 

Mehr von Colours B.V. (19)

How-To Sessies: Customer Journeys
How-To Sessies: Customer JourneysHow-To Sessies: Customer Journeys
How-To Sessies: Customer Journeys
 
Webinar - Predicting visitor behavior
Webinar - Predicting visitor behaviorWebinar - Predicting visitor behavior
Webinar - Predicting visitor behavior
 
SUGNL Colours - Otap & content delivery
SUGNL Colours - Otap & content deliverySUGNL Colours - Otap & content delivery
SUGNL Colours - Otap & content delivery
 
SUGNL Colours - Dms developer vs marketeer
SUGNL Colours - Dms developer vs marketeerSUGNL Colours - Dms developer vs marketeer
SUGNL Colours - Dms developer vs marketeer
 
SUGNL Colours - Git & branching
SUGNL Colours - Git & branchingSUGNL Colours - Git & branching
SUGNL Colours - Git & branching
 
Online trends | Gebruikerservaring (Whatsup 12/9/13)
Online trends | Gebruikerservaring (Whatsup 12/9/13)Online trends | Gebruikerservaring (Whatsup 12/9/13)
Online trends | Gebruikerservaring (Whatsup 12/9/13)
 
Van een op een, naar veel - Seminar Web, apps, email
Van een op een, naar veel - Seminar Web, apps, emailVan een op een, naar veel - Seminar Web, apps, email
Van een op een, naar veel - Seminar Web, apps, email
 
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?
Klantcase Eneco- Seminar Web, apps, email, hoe nu verder?
 
Ideale ontwikkelaanpak - Seminar Web, apps, email
Ideale ontwikkelaanpak - Seminar Web, apps, emailIdeale ontwikkelaanpak - Seminar Web, apps, email
Ideale ontwikkelaanpak - Seminar Web, apps, email
 
Multichannel - Seminar Web, apps,email
Multichannel - Seminar Web, apps,emailMultichannel - Seminar Web, apps,email
Multichannel - Seminar Web, apps,email
 
Case euromaster - colours voor Dutch Interactive Awards
Case euromaster - colours voor Dutch Interactive AwardsCase euromaster - colours voor Dutch Interactive Awards
Case euromaster - colours voor Dutch Interactive Awards
 
Wat is drupal? - Drupal seminar 20 mei 2010, Colours
Wat is drupal? - Drupal seminar 20 mei 2010, ColoursWat is drupal? - Drupal seminar 20 mei 2010, Colours
Wat is drupal? - Drupal seminar 20 mei 2010, Colours
 
Drupal in 5 vragen - Drupal seminar 20 mei 2010, Colours
Drupal in 5 vragen - Drupal seminar 20 mei 2010, ColoursDrupal in 5 vragen - Drupal seminar 20 mei 2010, Colours
Drupal in 5 vragen - Drupal seminar 20 mei 2010, Colours
 
Drupal & ISES, Drupal seminar 20 mei 2010, Colours
Drupal & ISES, Drupal seminar 20 mei 2010, ColoursDrupal & ISES, Drupal seminar 20 mei 2010, Colours
Drupal & ISES, Drupal seminar 20 mei 2010, Colours
 
Charlotte van dael DDMA Ilounge 9maart2010
Charlotte van dael DDMA Ilounge 9maart2010Charlotte van dael DDMA Ilounge 9maart2010
Charlotte van dael DDMA Ilounge 9maart2010
 
Hyves @ #Socialsucces 2 december 2009
Hyves @ #Socialsucces 2 december 2009Hyves @ #Socialsucces 2 december 2009
Hyves @ #Socialsucces 2 december 2009
 
Usability - Seminar Steeds Betere Website 24 nov 2009
Usability - Seminar Steeds Betere Website 24 nov 2009Usability - Seminar Steeds Betere Website 24 nov 2009
Usability - Seminar Steeds Betere Website 24 nov 2009
 
Verder Magazine van LECTRIC Groep
Verder Magazine van LECTRIC GroepVerder Magazine van LECTRIC Groep
Verder Magazine van LECTRIC Groep
 
Colours Bureaupresentatie
Colours BureaupresentatieColours Bureaupresentatie
Colours Bureaupresentatie
 

Kürzlich hochgeladen

lONG QUESTION ANSWER PAKISTAN STUDIES10.
lONG QUESTION ANSWER PAKISTAN STUDIES10.lONG QUESTION ANSWER PAKISTAN STUDIES10.
lONG QUESTION ANSWER PAKISTAN STUDIES10.lodhisaajjda
 
Dreaming Marissa Sánchez Music Video Treatment
Dreaming Marissa Sánchez Music Video TreatmentDreaming Marissa Sánchez Music Video Treatment
Dreaming Marissa Sánchez Music Video Treatmentnswingard
 
Digital collaboration with Microsoft 365 as extension of Drupal
Digital collaboration with Microsoft 365 as extension of DrupalDigital collaboration with Microsoft 365 as extension of Drupal
Digital collaboration with Microsoft 365 as extension of DrupalFabian de Rijk
 
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptx
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptxChiulli_Aurora_Oman_Raffaele_Beowulf.pptx
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptxraffaeleoman
 
If this Giant Must Walk: A Manifesto for a New Nigeria
If this Giant Must Walk: A Manifesto for a New NigeriaIf this Giant Must Walk: A Manifesto for a New Nigeria
If this Giant Must Walk: A Manifesto for a New NigeriaKayode Fayemi
 
Dreaming Music Video Treatment _ Project & Portfolio III
Dreaming Music Video Treatment _ Project & Portfolio IIIDreaming Music Video Treatment _ Project & Portfolio III
Dreaming Music Video Treatment _ Project & Portfolio IIINhPhngng3
 
My Presentation "In Your Hands" by Halle Bailey
My Presentation "In Your Hands" by Halle BaileyMy Presentation "In Your Hands" by Halle Bailey
My Presentation "In Your Hands" by Halle Baileyhlharris
 
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...amilabibi1
 
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdf
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdfThe workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdf
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdfSenaatti-kiinteistöt
 
Uncommon Grace The Autobiography of Isaac Folorunso
Uncommon Grace The Autobiography of Isaac FolorunsoUncommon Grace The Autobiography of Isaac Folorunso
Uncommon Grace The Autobiography of Isaac FolorunsoKayode Fayemi
 
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdf
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdfSOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdf
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdfMahamudul Hasan
 
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...David Celestin
 
Report Writing Webinar Training
Report Writing Webinar TrainingReport Writing Webinar Training
Report Writing Webinar TrainingKylaCullinane
 
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdf
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdfAWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdf
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdfSkillCertProExams
 

Kürzlich hochgeladen (15)

lONG QUESTION ANSWER PAKISTAN STUDIES10.
lONG QUESTION ANSWER PAKISTAN STUDIES10.lONG QUESTION ANSWER PAKISTAN STUDIES10.
lONG QUESTION ANSWER PAKISTAN STUDIES10.
 
Dreaming Marissa Sánchez Music Video Treatment
Dreaming Marissa Sánchez Music Video TreatmentDreaming Marissa Sánchez Music Video Treatment
Dreaming Marissa Sánchez Music Video Treatment
 
Digital collaboration with Microsoft 365 as extension of Drupal
Digital collaboration with Microsoft 365 as extension of DrupalDigital collaboration with Microsoft 365 as extension of Drupal
Digital collaboration with Microsoft 365 as extension of Drupal
 
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptx
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptxChiulli_Aurora_Oman_Raffaele_Beowulf.pptx
Chiulli_Aurora_Oman_Raffaele_Beowulf.pptx
 
If this Giant Must Walk: A Manifesto for a New Nigeria
If this Giant Must Walk: A Manifesto for a New NigeriaIf this Giant Must Walk: A Manifesto for a New Nigeria
If this Giant Must Walk: A Manifesto for a New Nigeria
 
Dreaming Music Video Treatment _ Project & Portfolio III
Dreaming Music Video Treatment _ Project & Portfolio IIIDreaming Music Video Treatment _ Project & Portfolio III
Dreaming Music Video Treatment _ Project & Portfolio III
 
My Presentation "In Your Hands" by Halle Bailey
My Presentation "In Your Hands" by Halle BaileyMy Presentation "In Your Hands" by Halle Bailey
My Presentation "In Your Hands" by Halle Bailey
 
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...
Bring back lost lover in USA, Canada ,Uk ,Australia ,London Lost Love Spell C...
 
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdf
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdfThe workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdf
The workplace ecosystem of the future 24.4.2024 Fabritius_share ii.pdf
 
Uncommon Grace The Autobiography of Isaac Folorunso
Uncommon Grace The Autobiography of Isaac FolorunsoUncommon Grace The Autobiography of Isaac Folorunso
Uncommon Grace The Autobiography of Isaac Folorunso
 
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdf
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdfSOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdf
SOLID WASTE MANAGEMENT SYSTEM OF FENI PAURASHAVA, BANGLADESH.pdf
 
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...
Proofreading- Basics to Artificial Intelligence Integration - Presentation:Sl...
 
Report Writing Webinar Training
Report Writing Webinar TrainingReport Writing Webinar Training
Report Writing Webinar Training
 
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdf
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdfAWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdf
AWS Data Engineer Associate (DEA-C01) Exam Dumps 2024.pdf
 
ICT role in 21st century education and it's challenges.pdf
ICT role in 21st century education and it's challenges.pdfICT role in 21st century education and it's challenges.pdf
ICT role in 21st century education and it's challenges.pdf
 

DUUG meetup Colours - Typescript

  • 1. TYPESCRIPT DUUG 25 SEPTEMBER 2014 4F )F1)F '1**-/FžF F3+ -/F¥F´%)1# '1**-/
  • 2. TYPESCRIPT LETS YOU WRITE JAVASCRIPT THE WAY YOU REALLY WANT TO.
  • 3. TYPESCRIPT 4+ . )/ -! . '.. . *0' . 0)/$*). ) -$.
  • 4. JAVASCRIPT TYPESCRIPT IS A TYPED SUPERSET OF JAVASCRIPT THAT COMPILES TO PLAIN JAVASCRIPT.
  • 5. BENEFITS *(+$' - 4+ F.! /4 0/*F*(+' /$*) '-/$*)F!$' .F¨ F
  • 6. $)F © )0'-‡%.F )
  • 7. TYPES /-$) 0( - **' ) --4 )0( )4 *$
  • 8. STRING / NUMBER / BOOLEAN var name: string = 'Jan'; var age: number = 24; var isDutch: boolean = true; name = isDutch; ))*/F*)1 -/FÞ**' )ÞF/*FÞ./-$)Þ‡
  • 9. ARRAY var list: number[] = [1, 2, 3]; list.push(4); list.push('five'); *0'F)*/F++'4F/4+ FÞ)0( -ÞF/*F-0( )/FtF2#$#F$.F*!F/4+ FÞ./-$)Þ‡
  • 10. ENUM enum Countries { 'Netherlands', 'Belgium', 'Unkown' } var country: Countries = Countries.Netherlands;
  • 11. ANY var notSure: any = 4; notSure = maybe a string instead; notSure = false; // okay, definitely a boolean
  • 12. INTERFACES interface IPerson { Name: string; Country: Countries; IsDutch: boolean; callName(): string; }
  • 13. INTERFACES class person implements IPerson { } '..F+ -.*)F '- .F$)/ -! F -.*)F0/F* .F)*/F$(+' ( )/F$/‰ 4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ( ÞF!-*(F/4+ FÞ -.*)Þ‡ 4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ*0)/$ .ÞF!-*(F/4+ FÞ -.*)Þ‡ 4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ .0/#ÞF!-*(F/4+ FÞ -.*)Þ‡ 4+ FÞ+ -.*)ÞF$.F($..$)F+-*+ -/4FÞ''( ÞF!-*(F/4+ FÞ -.*)Þ‡
  • 14. CLASSES class person implements IPerson { public Name: string; public Country: Countries; public IsDutch: boolean; constructor(name: string, country: Countries, isDutch: boolean) { this.Name = name; this.Country = Countries.Netherlands; this.IsDutch = isDutch; } callName() { return this.Name; } }
  • 15. CLASSES - A SHORTER WAY class person implements IPerson { constructor(public Name: string, public Country: Countries, public IsDutch: boolean) { } callName() { return this.Name; } }
  • 16. NEW CLASS var dave = new person('Dave Woestenborghs', Countries.Belgium, false);
  • 17. GENERICS function identityT(arg: T): T { return arg; } var output = this.identitystring('one'); var output = this.identitystring(1); 0++'$ F+-( / -.F*F)*/F(/#F)4F.$)/0- F*!F''F/- /‰ *0'F)*/F++'4F/4+ FÞ./-$)ÞF/*F-0( )/FtF2#$#F$.F*!F/4+ FÞ)0( -Þ‡
  • 18. TOOLS $.0'F/0$*FustvF0+/ Fu $.0'F/0$*FustuF¨ F
  • 19. $)F © 0'$( F 3/F¨ F
  • 23. DEMO