Cannot find module 'electron' after install exe on windows


#1

I can run the app with electron ./app

But after I pack it using electron-builder and install the .exe file. I got the following error:

I’m using:

    "electron-builder": "^5.4.1",
    "electron-prebuilt": "^1.2.3"

Does anyone know why this happens? How should do to solve it?

Thanks