SlideShare ist ein Scribd-Unternehmen logo
1 von 64
while42 meetup
JavaScript Sucks
How we deal with it
About Me
• Kyle Powers
About Me
• Kyle Powers
• Enterprise Cloud Meteorologist
About Me
• Kyle Powers
• Enterprise Cloud Meteorologist
• Also work on javascript 99% of my time
About Me
• Kyle Powers
• Enterprise Cloud Meteorologist
• Also work on javascript 99% of my time
• I like Sublime Text
JavaScript Quiz
Based on Gary Bernhardt’s “Wat” talk
WAT
WAT
WAT
WAT
WAT
WAT
End Quiz
• So how do we deal with this stuff?
How do we deal with this stuff
• Education
How do we deal with this stuff
• Education
• Testing
How do we deal with this stuff
• Education
• Testing
• Chrome developer console
Other bad things about JS
• Leaving off the “var” keyword makes a
variable global.
How we solve it
• When referencing a global variable “foo”, we
specify “window.foo” to make it clear that it’s
global
Other bad things about JS
• Callback hell
How we solve it
• Refactor – name functions outside of the
scope
• Keep functions shallow – usually no more than
2 levels deep
• Use the module pattern
"Write small modules that each do
one thing, and assemble them into
other modules that do a bigger
thing. You can't get into callback
hell if you don't go there.”
-Isaac Schlueter
Other useful tools
• type-check.js
• http://gkz.github.io/type-check/
If all else fails, blame it on IE6
Thanks
p.s. we’re hiring
kyle@clearslide.com
@mfkp
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7
Javascript sucks & frontend challenges @ClearSlide | while42 SF #7

Weitere ähnliche Inhalte

Was ist angesagt?

Angular – Say Goodbye to Javascript Soup
Angular – Say Goodbye to Javascript SoupAngular – Say Goodbye to Javascript Soup
Angular – Say Goodbye to Javascript Soup
Graeme Foster
 
Introduction to NodeJS
Introduction to NodeJSIntroduction to NodeJS
Introduction to NodeJS
Zahid Mahir
 
Customizing the custom loop wordcamp 2012-jeff
Customizing the custom loop   wordcamp 2012-jeffCustomizing the custom loop   wordcamp 2012-jeff
Customizing the custom loop wordcamp 2012-jeff
Alexander Sapountzis
 

Was ist angesagt? (20)

Php workshop L0 Introduction
Php workshop L0 IntroductionPhp workshop L0 Introduction
Php workshop L0 Introduction
 
Cleaning up your codebase with a clean architecture
Cleaning up your codebase with a clean architectureCleaning up your codebase with a clean architecture
Cleaning up your codebase with a clean architecture
 
Creating Hyper Performant Web Apps with React
Creating Hyper Performant Web Apps with ReactCreating Hyper Performant Web Apps with React
Creating Hyper Performant Web Apps with React
 
Freelancing and side-projects on Rails
Freelancing and side-projects on RailsFreelancing and side-projects on Rails
Freelancing and side-projects on Rails
 
Test Driven Development with AngularJS
Test Driven Development with AngularJSTest Driven Development with AngularJS
Test Driven Development with AngularJS
 
MongoDB: The Ultimate Backpack for the Cloud
MongoDB: The Ultimate Backpack for the CloudMongoDB: The Ultimate Backpack for the Cloud
MongoDB: The Ultimate Backpack for the Cloud
 
Introduction to HTML5
Introduction to HTML5Introduction to HTML5
Introduction to HTML5
 
Jira ICT - The magic of a fast website #jd11nl
Jira ICT - The magic of a fast website #jd11nlJira ICT - The magic of a fast website #jd11nl
Jira ICT - The magic of a fast website #jd11nl
 
Journey To The Front End World - Part3 - The Machine
Journey To The Front End World - Part3 - The MachineJourney To The Front End World - Part3 - The Machine
Journey To The Front End World - Part3 - The Machine
 
Design patterns - The Good, the Bad, and the Anti-Pattern
Design patterns -  The Good, the Bad, and the Anti-PatternDesign patterns -  The Good, the Bad, and the Anti-Pattern
Design patterns - The Good, the Bad, and the Anti-Pattern
 
Simplicity vs. Performance NSBCon NY by Jeffrey Palermo and Andrew Siemer
Simplicity vs.Performance NSBCon NY by Jeffrey Palermo and Andrew SiemerSimplicity vs.Performance NSBCon NY by Jeffrey Palermo and Andrew Siemer
Simplicity vs. Performance NSBCon NY by Jeffrey Palermo and Andrew Siemer
 
Angular – Say Goodbye to Javascript Soup
Angular – Say Goodbye to Javascript SoupAngular – Say Goodbye to Javascript Soup
Angular – Say Goodbye to Javascript Soup
 
Site Speed Hacks: Open West 2015
Site Speed Hacks: Open West 2015Site Speed Hacks: Open West 2015
Site Speed Hacks: Open West 2015
 
Extreme Javascript Minification
Extreme Javascript MinificationExtreme Javascript Minification
Extreme Javascript Minification
 
Untangling - fall2017 - week 7
Untangling - fall2017 - week 7Untangling - fall2017 - week 7
Untangling - fall2017 - week 7
 
PowerShell Runspaces
PowerShell RunspacesPowerShell Runspaces
PowerShell Runspaces
 
Introduction to NodeJS
Introduction to NodeJSIntroduction to NodeJS
Introduction to NodeJS
 
Untangling - fall2017 - week5
Untangling - fall2017 - week5Untangling - fall2017 - week5
Untangling - fall2017 - week5
 
Untangling - fall2017 - week6
Untangling - fall2017 - week6Untangling - fall2017 - week6
Untangling - fall2017 - week6
 
Customizing the custom loop wordcamp 2012-jeff
Customizing the custom loop   wordcamp 2012-jeffCustomizing the custom loop   wordcamp 2012-jeff
Customizing the custom loop wordcamp 2012-jeff
 

Andere mochten auch

Javascript Myths and its Evolution
Javascript Myths and its  EvolutionJavascript Myths and its  Evolution
Javascript Myths and its Evolution
Deepu S Nath
 
How to Use SlideRocket
How to Use SlideRocketHow to Use SlideRocket
How to Use SlideRocket
desousam5
 

Andere mochten auch (13)

Javascript Myths and its Evolution
Javascript Myths and its  EvolutionJavascript Myths and its  Evolution
Javascript Myths and its Evolution
 
While42 SF presentation | w42 #7 at ClearSlide
While42 SF presentation | w42 #7 at ClearSlideWhile42 SF presentation | w42 #7 at ClearSlide
While42 SF presentation | w42 #7 at ClearSlide
 
Sliderocket
SliderocketSliderocket
Sliderocket
 
Edtech lab presentations 7 30 15
Edtech lab presentations 7 30 15Edtech lab presentations 7 30 15
Edtech lab presentations 7 30 15
 
How to Use SlideRocket
How to Use SlideRocketHow to Use SlideRocket
How to Use SlideRocket
 
2collab London Online web2.0 after the buzz
2collab London Online web2.0 after the buzz2collab London Online web2.0 after the buzz
2collab London Online web2.0 after the buzz
 
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
 
Metarefresh
MetarefreshMetarefresh
Metarefresh
 
MIT OpenDocLab's StoryTools
MIT OpenDocLab's StoryTools MIT OpenDocLab's StoryTools
MIT OpenDocLab's StoryTools
 
Why ClearSlide
Why ClearSlideWhy ClearSlide
Why ClearSlide
 
ClearSlide
ClearSlide ClearSlide
ClearSlide
 
Agile Doesn't Work - Agile Twin Cities
Agile Doesn't Work - Agile Twin CitiesAgile Doesn't Work - Agile Twin Cities
Agile Doesn't Work - Agile Twin Cities
 
Pitch Deck Templates for Startups
Pitch Deck Templates for StartupsPitch Deck Templates for Startups
Pitch Deck Templates for Startups
 

Ähnlich wie Javascript sucks & frontend challenges @ClearSlide | while42 SF #7

Javascript orientado a testes
Javascript orientado a testesJavascript orientado a testes
Javascript orientado a testes
Alexandre Gomes
 
Polyglot and Poly-paradigm Programming for Better Agility
Polyglot and Poly-paradigm Programming for Better AgilityPolyglot and Poly-paradigm Programming for Better Agility
Polyglot and Poly-paradigm Programming for Better Agility
elliando dias
 

Ähnlich wie Javascript sucks & frontend challenges @ClearSlide | while42 SF #7 (20)

Leveling Up at JavaScript
Leveling Up at JavaScriptLeveling Up at JavaScript
Leveling Up at JavaScript
 
Drupal commerce performance profiling and tunning using loadstorm experiments...
Drupal commerce performance profiling and tunning using loadstorm experiments...Drupal commerce performance profiling and tunning using loadstorm experiments...
Drupal commerce performance profiling and tunning using loadstorm experiments...
 
Javascript orientado a testes
Javascript orientado a testesJavascript orientado a testes
Javascript orientado a testes
 
ClojureScript: I can't believe this is JavaScript
ClojureScript: I can't believe this is JavaScriptClojureScript: I can't believe this is JavaScript
ClojureScript: I can't believe this is JavaScript
 
Polyglot and Poly-paradigm Programming for Better Agility
Polyglot and Poly-paradigm Programming for Better AgilityPolyglot and Poly-paradigm Programming for Better Agility
Polyglot and Poly-paradigm Programming for Better Agility
 
Getting your mobile test automation process in place - using Cucumber and Cal...
Getting your mobile test automation process in place - using Cucumber and Cal...Getting your mobile test automation process in place - using Cucumber and Cal...
Getting your mobile test automation process in place - using Cucumber and Cal...
 
The JavaScript Delusion
The JavaScript DelusionThe JavaScript Delusion
The JavaScript Delusion
 
Blazing Fast Feedback Loops in the Java Universe
Blazing Fast Feedback Loops in the Java UniverseBlazing Fast Feedback Loops in the Java Universe
Blazing Fast Feedback Loops in the Java Universe
 
Testing gone-right
Testing gone-rightTesting gone-right
Testing gone-right
 
Introduction to the wonderful world of JavaScript
Introduction to the wonderful world of JavaScriptIntroduction to the wonderful world of JavaScript
Introduction to the wonderful world of JavaScript
 
ClojureScript Anatomy
ClojureScript AnatomyClojureScript Anatomy
ClojureScript Anatomy
 
All of Javascript
All of JavascriptAll of Javascript
All of Javascript
 
33rd degree
33rd degree33rd degree
33rd degree
 
Nashorn: JavaScript that doesn’t suck (ILJUG)
Nashorn: JavaScript that doesn’t suck (ILJUG)Nashorn: JavaScript that doesn’t suck (ILJUG)
Nashorn: JavaScript that doesn’t suck (ILJUG)
 
11 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 201411 Amazing things I Learnt At Word Camp Sydney 2014
11 Amazing things I Learnt At Word Camp Sydney 2014
 
3 years with Clojure
3 years with Clojure3 years with Clojure
3 years with Clojure
 
Qcon beijing 2010
Qcon beijing 2010Qcon beijing 2010
Qcon beijing 2010
 
Clojurescript slides
Clojurescript slidesClojurescript slides
Clojurescript slides
 
Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011Refactoring RIA Unleashed 2011
Refactoring RIA Unleashed 2011
 
Javascript Best Practices and Intro to Titanium
Javascript Best Practices and Intro to TitaniumJavascript Best Practices and Intro to Titanium
Javascript Best Practices and Intro to Titanium
 

Mehr von While42

Singapore chapitre #4 - You don't know
Singapore chapitre #4 - You don't knowSingapore chapitre #4 - You don't know
Singapore chapitre #4 - You don't know
While42
 

Mehr von While42 (14)

2 membres de while42 dans Programmez!
2 membres de while42 dans Programmez!2 membres de while42 dans Programmez!
2 membres de while42 dans Programmez!
 
while42 Marseille #1
while42 Marseille #1while42 Marseille #1
while42 Marseille #1
 
The Immigration reform
The Immigration reformThe Immigration reform
The Immigration reform
 
42 (school) at 2 years of while42
42 (school) at 2 years of while4242 (school) at 2 years of while42
42 (school) at 2 years of while42
 
La Silicon Valley vue par Camille Despringhere
La Silicon Valley vue par Camille DespringhereLa Silicon Valley vue par Camille Despringhere
La Silicon Valley vue par Camille Despringhere
 
Singapore chapitre #4 - You don't know
Singapore chapitre #4 - You don't knowSingapore chapitre #4 - You don't know
Singapore chapitre #4 - You don't know
 
Singapore chapitre #4 - Presentation
Singapore chapitre #4 - PresentationSingapore chapitre #4 - Presentation
Singapore chapitre #4 - Presentation
 
while42 mentionné dans la version papier du quotidien "Le Monde"
while42 mentionné dans la version papier du quotidien "Le Monde"while42 mentionné dans la version papier du quotidien "Le Monde"
while42 mentionné dans la version papier du quotidien "Le Monde"
 
Qemu - Raspberry | while42 Singapore #2
Qemu - Raspberry | while42 Singapore #2Qemu - Raspberry | while42 Singapore #2
Qemu - Raspberry | while42 Singapore #2
 
while42 Montreal #0 @ wajam
while42 Montreal #0 @ wajamwhile42 Montreal #0 @ wajam
while42 Montreal #0 @ wajam
 
Bugs from Outer Space | while42 SF #6
Bugs from Outer Space | while42 SF #6Bugs from Outer Space | while42 SF #6
Bugs from Outer Space | while42 SF #6
 
While42 SF #6: introducing while42 to Girls in Tech and Kwarter
While42 SF #6: introducing while42 to Girls in Tech and KwarterWhile42 SF #6: introducing while42 to Girls in Tech and Kwarter
While42 SF #6: introducing while42 to Girls in Tech and Kwarter
 
While42 Paris #1 - Presentation de while42
While42 Paris #1 - Presentation de while42While42 Paris #1 - Presentation de while42
While42 Paris #1 - Presentation de while42
 
Hack le droid
Hack le droidHack le droid
Hack le droid
 

Kürzlich hochgeladen

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
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...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
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
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 

Javascript sucks & frontend challenges @ClearSlide | while42 SF #7