I am building a simple editor-type application in react-redux, and I want to mimic the operation of downloading and uploading json files for saving and loading data - entirely client side. The server side does not need the data. Local storage may be too small, and it would be nice to provide the user the data in a portable file they could upload on a new machine. Is this even possible, and if so how?
Asked
Active
Viewed 2,645 times
1 Answers
0
Using a blob
file.
You can set the content of a new file which is temp and local, then trigger a click event to download the file.

mewc
- 1,253
- 1
- 15
- 24
-
I appreciate your attempt at an answer, but of the 3 possibilities provided, only 1 performs the download behavior I want - and it doesn't work. I think browsers are now blocking dynamically clicking links. Additionally, your answer does not address the upload behavior at all - but I figured that one out. – Danny Ellis Jr. Dec 08 '18 at 01:58