CONCEPTS
typeof "hello" // "string" (primitive)
typeof 42 // "number" (primitive)
typeof true // "boolean" (primitive)
typeof undefined // "undefined" (primitive)
typeof null // "object" (but technically primitive)
typeof {} // "object" (reference type)
typeof [] // "object" (reference type)
typeof function(){} // "function" (but technically object)
- https://www.typescriptlang.org/docs/handbook/mixins.html
-
Stacks
Queues
- Codecademy - Arrays Cheatsheet
- .indexOf()
- .slice()
- .pop()
- Codecademy
- https://www.linkedin.com/learning/javascript-arrays/the-end-push-and-pop-data
- https://lodash.com/docs/4.17.15#dropRight
- .push()
- Codecademy
- https://www.linkedin.com/learning/javascript-arrays/the-end-push-and-pop-data
- .unshift()
- Codecademy
- https://www.linkedin.com/learning/javascript-arrays/the-beginning-unshift-and-shift-data
- https://lodash.com/docs/4.17.15#concat
- .shift()
- Codecademy
- https://www.linkedin.com/learning/javascript-arrays/the-beginning-unshift-and-shift-data
- https://lodash.com/docs/4.17.15#drop
- .reverse()
- https://www.linkedin.com/learning/javascript-arrays/reverse-array-order-with-reverse
- .sort()
- https://www.linkedin.com/learning/javascript-arrays/order-arrays-with-sort
- includes()
- MDN Web Docs - find()
- MDN Web Docs - Uint8Array.slice()
- https://www.youtube.com/playlist?list=PLRqwX-V7Uu6bO9RKxHObluh-aPgrrvb4a
- https://www.youtube.com/playlist?list=PLRqwX-V7Uu6aAEUqu96Newc-7qpuh-cxc
- Rachel Cole - Top 10 JavaScript Array Methods You Should Know
- Tabassum Khanum - 15+ Array Methods in Javascript
Does not return a reference copy.
Higher Order Function - The return value for .forEach() will always be undefined.
Higher Order Function - The return value for a map() is always a new array.
- https://www.codecademy.com/resources/docs/javascript/arrays/map
- https://www.linkedin.com/learning/javascript-arrays/reformat-data-with-map
Higher Order Function
Should return true or false. If true, the return value is the elements after filtering out false elements from the original array.
- https://www.codecademy.com/resources/docs/javascript/arrays/filter
- https://www.linkedin.com/learning/javascript-arrays/filter-data-with-filter
Higher Order Function
Contains accumulator (acc) and iterator (currentValue).
- https://www.geeksforgeeks.org/javascript/javascript-array-reduce-method
- https://www.linkedin.com/learning/javascript-arrays/single-values-with-reduce
Higher Order Function
- https://www.geeksforgeeks.org/javascript/javascript-array-find-method
- https://www.linkedin.com/learning/javascript-arrays/find-a-single-element-with-find-and-findindex
Higher Order Function
If there isn’t a single element in the array that satisfies the condition in the callback, then .findIndex() will return -1.
- https://www.codecademy.com/resources/docs/javascript/arrays/findIndex
- https://www.linkedin.com/learning/javascript-arrays/find-a-single-element-with-find-and-findindex
Higher Order Function - All elements in the array match to true.
Higher Order Function - At least one element in the array match to true.
Map that transforms an array into a flat structure.
- https://www.linkedin.com/learning/javascript-arrays/3144066
- https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ajGB2OI3hl5DZsD1Fw1WzR
- https://www.geeksforgeeks.org/maths/composition-of-functions
- https://www.geeksforgeeks.org/javascript/javascript-memoization/
- MDN Web Docs - Error
- https://www.codecademy.com/resources/docs/javascript/errors
Fetch is newer and not built on top of XHR. Usage of Asynchronous JavaScript and XML (AJAX) through JSON.
Usage of Asynchronous JavaScript and XML (AJAX) through JSON.
- https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest