JavaScript flash cards: Freelancer level

58 JavaScript terms at the Freelancer level, as flash cards.

Updated

Terms in this deck

<slot>
The element that marks where assigned light-DOM content appears inside a shadow tree.
<template>
The element that stores inert HTML fragments for later use.
AbortController
An object that sends cancellation signals to APIs such as fetch.
Async Iterator
An iterator whose next() method returns a Promise for each result.
Autonomous custom element
A custom element with its own hyphenated tag name.
Babel
A JavaScript compiler commonly used to transform newer syntax for older environments.
CommonJS
The Node.js module format based on require() and module.exports.
Currying
Transforming a function with several parameters into a sequence of one-parameter functions.
Custom element
An author-defined HTML element whose behavior is registered through the Custom Elements API.
Customized built-in element
A custom element that extends a built-in HTML element and uses the is attribute.
Cypress
A popular in-browser end-to-end testing tool.
Debounce
A technique that delays work until rapid calls have stopped for a chosen time.
Declarative shadow DOM
HTML syntax that creates a shadow root from a template element during parsing.
Deep Copy
A copy of a collection and everything inside it, fully separate.
Dynamic Import
The import() expression, which loads a module asynchronously when requested.
ESLint
A configurable tool that reports problems and style issues in JavaScript code.
Event Bubbling
The phase in which an event moves from its target up through ancestor elements.
Event Capturing
The phase in which an event travels from ancestors down toward its target.
Event Delegation
Handling events for many descendants with one listener on a shared ancestor.
Event Object
An object containing information about an event that occurred.
Event Target
The object on which an event was originally dispatched.
for await...of
A loop that awaits and visits values from an async iterable.
Generator Function
A function declared with function* that can pause and yield several values.
Immutability
The practice of creating new values instead of changing existing ones.
Iterable
Anything you can loop over with for.
Iterator
Gives out items one at a time with next() and remembers where it is.
Iterator Protocol
The next() method contract used to produce a sequence of values.
Local Storage
Browser key-value storage that remains after the page and browser are closed.
Map
A collection that associates unique keys with values.
Memoization
Caching a function's result so repeated inputs can return it without recalculation.
Mock Function
A test function that records calls and can return controlled values.
Module Bundler
A tool that combines a module graph into files prepared for deployment.
Named slot
A slot identified by name so matching host children can be assigned to it.
preventDefault()
An Event method that cancels the browser's default action when the event is cancelable.
Promise.all()
A method returning a Promise that fulfills when every input fulfills or rejects when one rejects.
Promise.allSettled()
A method returning results for every input after all have settled.
Promise.any()
A method returning the first fulfilled input or rejecting if all inputs reject.
Promise.race()
A method returning a Promise that settles when the first input settles.
Regular Expression
A pattern for finding or checking text.
Session Storage
Browser key-value storage kept for one tab's browsing session.
Set
A collection with no duplicates and no set order.
Shadow host
An element to which a shadow root is attached.
Shadow root
A document fragment that forms the root of a component's encapsulated shadow tree.
Shallow Copy
A new collection that still shares the items inside it with the original.
Slot assignment
The process that matches a shadow host's children with slots in its shadow tree.
Source Map
A file connecting transformed code locations back to the original source.
stopPropagation()
An Event method that stops the event from moving to other elements.
Strict Mode
A JavaScript mode that rejects some error-prone behavior and changes certain runtime rules.
structuredClone()
A function that makes a deep copy of many built-in JavaScript values.
Symbol
A primitive whose values are always unique and can be used as object property keys.
Throttle
A technique that limits how often repeated calls may run.
Transpiler
A tool that converts source code into another version of source code.
Tree Shaking
Removing exports that a build can determine are unused.
Unit Test
A small automated check of one focused unit of behavior.
WeakMap
A Map-like collection with weakly held object or non-registered Symbol keys.
WeakSet
A Set-like collection holding objects weakly so it does not prevent garbage collection.
Web Worker
A browser worker that runs JavaScript away from the page's main thread.
yield
Hands back one value from a generator and pauses until the next one is needed.

Read them in the glossary