I'm developing a little app in Electron from which I can upload an image to Instagram and I'm stuck at one of the first steps :/
I want to select an image from the filesystem and display it in my app.
This is the code I've got so far:
CODE:
remote.dialog.showOpenDialog((filenames) => {
fs.readFile(filepath, 'utf-8', (err, data) => {
if(err){
alert("An error ocurred reading the file :" + err.message);
return;
}
});
});