I wanted to know if there's a way to load a JS file, located on my computer, on my browser.
I know it's possible with Firefox with Scratchpad, but could it be with Chrome or whatever else?
I wanted to know if there's a way to load a JS file, located on my computer, on my browser.
I know it's possible with Firefox with Scratchpad, but could it be with Chrome or whatever else?
Copyright © 2021 Jogjafile Inc.
Yes, it is possible with Chrome/Chromium. You can store the file at
LocalFileSystemusingwebkitRequestFileSystemand get a reference the file usingFileEntry.toURL()which returns afilesystem:protocol URL.Alternatively, use
<input type="file">to upload the file object or folder andURL.createObjectURL()to reference the file as aBlob URL.