the instruction will lead you to the error. since if you want to add env.js to the index.html file, you must do that in public folder.
this folder falls out of src folder and you can't import it to your jsx files inside of src, because of this reason.