question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature] Set File.path property when uploading files with Electron

See original GitHub issue

My application uses the q-file feature of the quasar framework.here is the q-file link. When a file is uploaded, it gets the path parameter of the file in the files object array to find the local address where the file is located. This is the file object printed in Developer tools after I uploaded the file manually, you can see the properties ‘path’ is not empty hand I uploaded the file using setInputFiles() and ‘path’ is empty. await window.locator('input[type="file"]').setInputFiles(path.resolve(__dirname, '../cypress/fixtures/samples/GoneNutty.avi')) 1637820410(1) I know setInputFiles() has only 3parameters,can I still use other methods to achieve passing ‘path’,if you see my problem I hope you can help me,thanks a lot.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:2
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
alphabiz-se4commented, Nov 27, 2021

I forgot to tell you that I was using playwright’s Electron() method to test our electron version of the app. i found some information on the electron website and they had added a path attribute to the File interface. see here

1reaction
monica-xucommented, Feb 17, 2022

hi, @mxschmitt how about this function now, I met the same issue about the file path being empty in electron, did the playwright already solve it?

Read more comments on GitHub >

github_iconTop Results From Across the Web

File Upload in ElectronJS - GeeksforGeeks
This tutorial will use the instance method of the dialog module to demonstrate File Upload functionality in Electron.
Read more >
Working with files (I/O) in an Electron application - Medium
First of all, appDir is the directory path on the filesystem where the files uploaded on this application will be stored. The os....
Read more >
Electron: get full path of uploaded file - node.js - Stack Overflow
Electron adds a path property to File objects, so you can get the real path from the input element using: document.
Read more >
Electron.js File Upload with Full Path (Full Application Easy ...
Electron.js File Upload with Full Path (Full Application Easy and Simple Tutorial 2019)Download Source Code of the Application ...
Read more >
Electron Drag and Drop File Upload Editing Application
Electron Drag and Drop File Upload Editing Application - Coding ShikshaDownload the Source Code of the Application ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found