That has nothing to do with Notepad++. Whatever editor you use to type your HTML+JavaScript, the browser will treat it the same.
There might be new security settings on Edge and/or Firefox (and/or Chrome) which allow local JavaScript or not. But that becomes a question for experts in your browser of choice, not for experts in your editor of choice. I highly recommend finding a forum for your browser, and asking there why the same HTML+JavaScript will work on the remote online server, but won’t work when you try to render a local copy of the page.