How to list all the exe files intsalled in local PC using electron

I want to list all the exe files (application) installed in the local system.I want to launch that app from electron application.
I tried
indent preformatted text by 4 spaces
const { execSync } = require(‘child_process’);
const exeFiles=execSync(‘where *.exe’);
console.log( exeFiles); //it lists exe but not all I think

and also this.

 let list = execSync('wmic product get name,version');

returns only name and version.this will take some time.I installed candy crush game .but its exe is not listed in both of the command’s result.Is there any other way to list .please help

By default, where only searches the current directory and all directories in the PATH. This would find all of the applications that you could launch from a generic command line.

To find all exe files you need something like:
dir /s c:*.exe

On my system, that found over 8000 files, so I suspect that you need something that is much more specific.

Is there any option to give sepecific exe file name along with where or dir.if I give dir /s c:spotify.exe. dir returns path of that spotify ,but it take time to return the path of specified exe .so If I want to get 10 apps exe then it takes high time .