How to Save a file at client side using JavaScript?

前端 未结 6 559
一生所求
一生所求 2020-12-11 06:44

I want to save a JSON object to a file at client to persist it for future usage, I have tried following line

window.open(\"data:text/json;charset=utf-8,\" + es

6条回答
  •  猫巷女王i
    2020-12-11 07:11

    If you want to persist data, then use a storage API, you can't play games with the user's filesystem.

提交回复
热议问题