A proxy is a gateway between a client and the entire internet. But there are several use cases for a proxy. For example: if you’re inside a corporate network, there are 99% chances that you’re behind a proxy which controls your access to the internet by allowing and restricting what you can visit and what you can’t visit. Such kind of proxy is known as forward proxy.

If we talk about server side, let’s say you are having an application deployed on some servers and are exposed to internet, but you want to implement a middleman which can prevent the…


JS callbacks
JS callbacks

If you code, it is certain that you use methods and functions no matter what programming language you are using. In javascript, since a lot of things works asyncronously, callbacks add a great feature to perform the post tasks. Let’s dive deep into it and understand what are they and how they work.

Let’s write a simple javascript function which returns a number

const getNumber = () => { 
return 10
}
console.log(getNumber())

This code is self explanatory. A function getNumber() when called returns a number 10 and logs it in console.

[thejsway@jsmachine]$ node callback.js
10

Now, let’s do some…

Tejaswi Kasat

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store