If you have to change some things in renderer.js or main.js but you want to do the changes in index.html, you can use the remote function. It lets you access all the electron functions you need!
require("electron")
:
main.js: const electron = require("electron");
index.html: const electron = require("electron").remote;