Skip to content

Latest commit

 

History

History
191 lines (152 loc) · 8.37 KB

javascript.md

File metadata and controls

191 lines (152 loc) · 8.37 KB

There are so many javascript libraries. Doesn't mean to be a know it all. Here are the ones I come across.

  • PollyJS - retry policy
  • InversifyJS - dependency injection
  • router
  • Axios or Fetch
  • Async - Redux, Trunk, Saga : validation, API calls, error handling, trigger redux mutations, or trigger a notification
  • Class components vs Functional components: Understanding Functional Components vs. Class Components in React
  • React hooks connect()
  • Redux async - for validation, checking and other

Official doc

basic tutorial

In depth tutorial

interview questions

sample code

Virtual DOM.

  • https://medium.com/devinder/react-virtual-dom-vs-real-dom-23749ff7adc9 Real vs Virtual DOM vs Shadow Dom dirty checking - traverse the entire tree at regular interval. Expensive and slow observable - components listen on events when there is update. Fast.
    Virtual DOM is an abstraction of the real DOM. light weight. recreated after every render. Reconciliation does compare and sync the virtual dom to the read DOM. It uses diffing algorithm. Updated real DOM is rendered again.

event loop

design patterns

testing

debugging

console.log({name,age,gender});
console.log( "plain text, %ccolored text", "color:green; font size:15px" );
console.warn("watch out");
console.error("you got an error");
console.table(["apples", "oranges", "bananas"]);
DEBUG=express* node index.js
npm install -g node-inspector
node-debug index.js --debug-brk

node debug app.js c => continue with code execution n => execute this line and go to next line s => step into this function o => finish function execution and step out repl => allows code to be evaluated remotely

node token

 git+https://oauth2:[email protected]:6443/somegit
 git+https://<token-from-github>:[email protected]/<user>/<GitRepo>.git

refactor

Node in general

Node setup

node alternative

  • deno Deno
  • flyjs flyJs specific for Edge application. The Fly JavaScript runtime

Scaffolding in general

There are many packages out there. Webpack, Yeoman, Grunt, jsHint, Slush

Bootstrap

Yarn

Gulp

Parcel

WebPack

Grunt

Yeoman

Slush

Lint checker

There are many. JsHint, ESLint

transpiling ES6

express

  • express the concept of middleware. Using promise to wait for all async all to come back unit testing mocha, chai, sinon, istanbul
  • express-generator to generate the source code.
 npm install express-generator -g

integration

SalesForce integration

file system API