NodeJs

NodeJS API- Express

Nodejs is basically a way to run javascript outside the context of the browser. Powered by V8. We can use node for many things now like tooling and servers. To get started, you can just type node in your terminal and you'll have a full JS REPL. Note that this is just Javascript but it's not in the context of… Continue reading NodeJS API- Express

Advertisements
NodeJs

Callback function

- Callback   what's Callback function? callback function is a function which is passed to another function as an argument. and the callback function is called (or executed) inside the other function. Basic Example var getUser = (id, callback) => { var user = { id: id, name: 'Ahmed' }; callback(user); }; getUser(31, (userObject) => {… Continue reading Callback function

NodeJs

Relation between CommonJS, AMD and RequireJS?

  What are JavaScript modules? What is their purpose? Definition: how to encapsulate a piece of code into a useful unit, and how to register its capability/export a value for the module. Dependency References: how to refer to other units of code. CommonJS is a way of defining modules with the help of an exports object, that defines… Continue reading Relation between CommonJS, AMD and RequireJS?

ReactJS

ReactJs – Component Life Cycle

React provides developers with many methods or “hooks” that are called during the life-cycle of an component, which allows us to update the UI and application state. Knowing when to use which of them is crucial to properly understanding how to work with React. ReactJs is a javascript library for building user interfaces. What is User… Continue reading ReactJs – Component Life Cycle

javascript

ES6 – Promises

Callback what's Callback function? callback function is a function which is passed to another function as an argument. and the callback function is called (or executed) inside the other function. Basic Example var getUser = (id, callback) => { var user = { id: id, name: 'Ahmed' }; callback(user); }; getUser(31, (userObject) => { console.log(userObject); });… Continue reading ES6 – Promises