You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am creating the element using the document.createElement('input') inside the JS function. I am calling that function using the JsIsolatedWorker().run(functionName: 'alertMessage',arguments: '100') It is giving me error:
This is my JS function. I am getting image using input type=file. Plan is to return file path from this function.
async function createDynamicInput() {
var input = document.createElement('input');
input.type = 'file';
input.onchange = e => {
var file = e.taralertMessageget.files[0];
console.log(file);
return file;
}
input.click();
}
Calling this function using:
var result = await JsIsolatedWorker().run(
functionName: 'createDynamicInput',
arguments: '100',
);
print("==$result");
Error: ReferenceError: document is not defined.
Let me know the correct way or require to make changes into current code. Thanks
The text was updated successfully, but these errors were encountered:
I am creating the element using the
document.createElement('input')
inside the JS function. I am calling that function using theJsIsolatedWorker().run(functionName: 'alertMessage',arguments: '100')
It is giving me error:This is my JS function. I am getting image using input type=file. Plan is to return file path from this function.
Calling this function using:
Error: ReferenceError: document is not defined.
Let me know the correct way or require to make changes into current code. Thanks
The text was updated successfully, but these errors were encountered: