SSShivam Sharmainshivamsharma.hashnode.dev·Jan 27, 2021 · 4 min readHow to close the dropdown when clicked outside its division in React.During my internship. One day I was working on building some dropdown filters for our company's product. Initially, I thought yeah it's not too big a deal. I can simply store one state and render the list on setting the state as true. So initial phas...01C
SSShivam Sharmainshivamsharma.hashnode.dev·Jan 16, 2021 · 3 min readJavascript and React learnings of some past months.1.) _isMounted I recently found out about this when one of my colleague used this in his code and then I found out that in order to check whether our React component is mounted or not we can use this._isMounted in our lifecycle methods and it will re...00
SSShivam Sharmainshivamsharma.hashnode.dev·Sep 7, 2020 · 3 min readUnderstanding the difference between let, var char and const in JavaScriptUnderstanding the difference between let, var char and const in JavaScript Let us begin with understanding var . It is the oldest way to declare variables in JavaScript Scope of var: var variables are globally as well as function/locally scoped .It m...00