Also most probably you need to serve it over local http server, opening files directly may not work -this is what the error message is telling - scheme 'http' or 'https' is needed, so "file://" may not work. Not only because of CORS but also Web Bluetooth API will not work from directly opened local files for security reasons (please correct me if I am wrong).
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Also most probably you need to serve it over local http server, opening files directly may not work -this is what the error message is telling - scheme 'http' or 'https' is needed, so "file://" may not work. Not only because of CORS but also Web Bluetooth API will not work from directly opened local files for security reasons (please correct me if I am wrong).