javascript

javascript

dz / javascript

Summary

things related to the javascript programming language

Node Tree

Nodes

js_questions
content Front End Interview: JavaScript Questions
children how_event_delegation_works (found via), simple_rules_to_this (found via)
hyperlink https://www.frontendinterviewhandbook.com/javascript-questions

how_event_delegation_works
content how event delegation works
parents js_questions
hyperlink https://davidwalsh.name/event-delegate

simple_rules_to_this
content The Simple Rules to "this" in JavaScript
parents js_questions
hyperlink https://codeburst.io/the-simple-rules-to-this-in-javascript-35d97f31bde3

dom_event_delegation_stack_overflow
content Stack overflow: what is event delegation?
hyperlink https://stackoverflow.com/questions/1687296/what-is-dom-event-delegation

js_objects
content JavaScript Objects: Inherited a Mess
hyperlink https://davidwalsh.name/javascript-objects

the_core
content JavaScript: The Core
hyperlink http://dmitrysoshnikov.com/ecmascript/javascript-the-core/

mdn_prototype_chain
content Inheritance and the Prototype change
children instanceof (checks prototype chain)
hyperlink https://developer.mozilla.org/en-US/docs/Web/JavaScript/Inheritance_and_the_prototype_chain

IIFE
content Immediately Invoked Function Expression
hyperlink https://en.wikipedia.org/wiki/Immediately_invoked_function_expression
flashcard (front) What is an IIFE?
flashcard (back) An Immediately Invoked Function Expression, or IIFE, is a programming language idiom which produces a lexical scope using function scoping. Example =(function () { })();=. It was a popular way to do modular programming in JS before ES modules and CommonJS.

this
content this
flashcard (front) explain "this" in JavaScript
flashcard (back) 1. new keyword used: brand new object. 2. apply/call/bind: object passed in as argument. 3. obj.method(): object that function is property of 4. free function invocation: global object. window in the browser, undefined in strict mode. 5. multiple rules apply: higher rule wins. 6. arrow function in ES2015: ignore previous rules, use encapsulating scope.

coercion
content coercion: an automatic conversion of values from one data type to another. Ex: having 0 coerce itself to be false.
children type_coercion_mdn
parents truthiness
flashcard (front) What is coercion in javascript?
flashcard (back) An automatic conversion of values from one data type to another. (ex: 0 to false)

truthiness
content truthiness: When value is considered true when encountered in a boolean context.
children coercion (A value is said to be coerced to a boolean value)
hyperlink https://developer.mozilla.org/en-US/docs/Glossary/Truthy

type_coercion_mdn
content MDN: type coercion
parents coercion
hyperlink https://developer.mozilla.org/en-US/docs/Glossary/Type_coercion

instanceof
content instanceof: tests to see if the prototype property of a constructor appears anywhere in the prototype chain of an object.
parents mdn_prototype_chain
flashcard (front) what does instanceof of?
flashcard (back) instanceof is a javascript operator that checks to see if a prototype property exists anywhere in the prototype chain of an object

rest_parameter
content Rest Parameter: syntax that allows a function to accept an indefinite number of arguments as an array, providing a way to represent variadic functions in javascript. ex: =function sum(...theArgs)=
hyperlink https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/rest_parameters
flashcard (front) What are rest parameters?
flashcard (back) Rest parameter syntax in JS allows for variadic functions to be represented as an array. Ex: =function sum(..theArgs)=.