• JavaScript

    Get list of all global npm packages installed

    Sometimes I get conflicts in path and get confused between globally and locally installed npm packages. So I need to find out what packages I installed globally. I googled it and found out how (duhhh) Putting here for my reference or may be others can get too.

    (–depth – Max display depth of the…

  • HTML, JavaScript

    Handle Cancel Click on File Input

    Ever Tried capturing cancel event on Browse file input type in HTML, tbh there is no direct way to do so But there is a workaround adding a bit of javascript. We can play with onfocus event of the BODY element. Example -> HTML


    See it working here