Kurs i JavaScript

Kurs i JavaScript programmering för både client-side och server-side

Denna praktiskt inriktade kurs vänder sig till dig som snabbt behöver bli produktiv och förstå hur man programmerar i JavaScript på ett effektivt och säkert sätt.

Vi fokuserar på det goda sidorna av språket och pekar ut vilka fallgropar du bör undvika. Framför allt så demystifierar vi objekt begreppet i JavaScript, som dessvärre är helt väsensskillt från hur det fungerar i språk såsom Java.

Detta får du lära dig
  • Förstå hur objekt modellen (prototype) fungerar
  • Förstå hur funktionsuttryck (lambda) fungerar
  • Förstå hur språkets typsystem fungerar
  • Undvika vanliga fallgropar
  • Kunna använda ES2015 och senare versioner
  • Kunna förstå och programmera asynkrona program
  • Kunna skriva och exekvera enhetstest
Kursinnehåll

Background and Overview

  • History
  • Brendan Eich
  • Why the name JavaScript, when it's not Java
  • What is ECMAscript and ES*
  • Upcoming releases
  • NodeJS adn Ryan Dahl
  • Brief about NodeJS
  • Using NPM
  • How to run JavaScript from the command line
  • How to run JavaScript in a browser
  • Installation of NodeJS and NPM

Basic Syntax

  • Program structure
  • Expressions and statements
  • Variables
  • Operators
  • Literals
  • Control structures
  • Syntactic pitfalls
  • Boolean values
  • Falsy and truthy
  • Numbers
  • Text strings
  • Regex
  • Array
  • Objects
  • The typeof operator
  • Type conversion rules for operator ==
  • Why it is better to always use operator ===
  • Type conversion pitfalls

Functions

  • Function statement
  • Function invocation
  • Parameter passing
  • Recursive functions
  • Function reference
  • Function expressions
  • Lambda expressions (aka fat arrows)
  • Scope rules
  • Free variables
  • Immediately invoked function expression (IIFE)
  • The module pattern

Understanding the Object Model

  • The prototype model
  • Class-like objects
  • Using new
  • Understanding this
  • Properties
  • Methods
  • Inheritance

Text Functions

  • Selector functions
  • Creator functions
  • Search related functions
  • Regex
  • Regex using functions

Array Functions

  • Basic array functions
  • Update functions
  • Sort and search related functions
  • Array pipeline stream expressions
  • Using filter, map and reduce

Date Functions

  • Date constructors and factory methods
  • Acceptable formats for parsing
  • Getters and setters

Misc. Functions

  • Post-poned execution using timeout
  • Periodic computation using interval timers
  • Math functions
  • URL encoding
  • Dynamic evaluation of JS expressions

JSON

  • What is JSON
  • JSON data types
  • Generting a JSON text string
  • Pretty printing
  • Using a properties replacer during JSON serialization
  • Generating a JSON expression based on a subset of properties
  • Parsing a JSON text string
  • Parsing with a properties replacer
  • Replacing the JSON result with a toJSON function
  • What is YaML
  • Benefits of using YaML for configuration files

JavaScript Execution Model

  • JavaScript engines
  • Understanding the call-stack and stack-frames
  • Invocation of asynchronous function blocks
  • The event-loop
  • A model for understanding how JS executes
  • Using Loupe to visualize JS execution

IIFE and Modules

  • What is an IIFE
  • How is IIFE working
  • What are the benefits of IIFE
  • Understanding the module pattern
  • Modules in JS

ES6

  • Features
  • Browser support
  • Default parameters
  • Multi-assignment
  • Spread operator
  • Set & Map data-structures
  • Lambda expressions
  • Classes
  • Getters & Setters
  • Inheritance
  • Modules
  • Iterators
  • Generators
  • Co-routines

Asynchronous Computation

  • What is async computation
  • Execution models
  • Using call-back functions
  • Limitations of the call-back model
  • Understanding promise objects
  • Promise syntax
  • Using promises to postpone computation
  • Assembling promise chains
  • Promise barrier
  • Handling of errors in promise chains
  • Understanding async functions
  • Creatting async functions
  • Waiting for promises using await

Understanding the DOM API

  • Browser API
  • What is the DOM
  • Node tree
  • Embedding and linking to JS code
  • Attributes of the script tag
  • Embedding and linking to CSS code
  • Attributes of the link tag
  • Finding elements/nodes in a DOM tree
  • Common DOM document properties
  • Some array-like properties and how to use them
  • Dealing with element/node content
  • Dealing with CSS styles
  • Structurally modifying a DOM tree

DOM Events

  • What is an event and an event handler
  • Different ways to register an event handler
  • Common event properties
  • Click events
  • Form events
  • Keyboard events
  • Common key event properties
  • Listening and reacting to key events
  • Mouse events
  • Listening and reacting to mouse events
  • Browser events
  • Understanding the event propagation model
  • Bubbling vs. capturing
  • How to create events and emit them

Understanding the BOM API

  • What is the BOM API
  • Using the window object
  • Using the lcoation object
  • Understanding browser storage
  • Using local and session storage
  • Storage operations

AJAX Fundamentals

  • Brief about the HTTP protocol
  • HTTP operations
  • HTTP response codes
  • MIME types
  • Brief about HTTPS
  • What is AJAX (or AJAJ)
  • Using the XMLHttpRequest object
  • Synchronous AJAX operation
  • Asynchronous AJAX operation
  • Brief about RES web services
  • Brief about CORS and why it's important to know about it

Unit testing

  • Unit testing in JS
  • Installation of Jasmine
  • Writing Jasmine test functions
  • Overview of expect matchers
  • Jasmine life-cycle methods
  • Selectively running tests
  • Testing async code

Transpiled languages

  • What is transpilation
  • What is TypeScript (TS) and why is so popular
  • Installation of typescript
  • Type support examples in TS
  • Classes in TS
  • Getters and setters in TS classes
  • Generic classes in TS
  • What is CoffeeScript
  • What is GrooScript

Useful libraries and tools

  • Lodash - Versatile utilities
  • Underscore - Prequel to lodash
  • MomentJS - Powerful date handling
  • jQuery - Simple DOM/BOM/AJAX handling
  • ExpressJS - REST web services server
  • GulpJS - the build tool
  • Bower - the library manager
  • Yeoman - the skeleton and snippet manager
SnabbFakta
NamnJavaScript
Längd3 Dagar
NivåBeginner
MålgruppProgrammerare
FörkunskaperKunnande i något program/scrip-språk
Verktyg
  • NodeJS
  • JetBrains WebStorm IDE
  • Google Chrome browser
KursDatum
DatumPlats PrisBoka
Hämtar kursschema...
19000

Samma-Företags Rabatt

Vi ger 20% rabatt för tillkommande deltagare från samma företag vid samma kurs-tillfälle. Läs mer här.

Företagsintern Kurs

Om du beställer en företagsintern kurs kommer vi till er och håller kursen i era lokaler. Priset bestäms av vår prismodell och baseras på antalet kursdagar, antalet deltagare, samt i förekommande fall resa och logi.

Läs mer om vår prismodell och beställningsvillkor här.

Relaterade Kurser
KursDagarNivå
TypeScript2IntermediateVisa
NodeJS2IntermediateVisa
GulpJS2 BeginnerVisa