Browse Source
Merge pull request #375 from Saibamen/format_backup_json
Format JSON file before download
pull/376/head
Louis Lam
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
src/pages/Settings.vue
|
|
@ -383,7 +383,7 @@ export default { |
|
|
|
notificationList: this.$root.notificationList, |
|
|
|
monitorList: monitorList, |
|
|
|
} |
|
|
|
exportData = JSON.stringify(exportData); |
|
|
|
exportData = JSON.stringify(exportData, null, 4); |
|
|
|
let downloadItem = document.createElement("a"); |
|
|
|
downloadItem.setAttribute("href", "data:application/json;charset=utf-8," + encodeURI(exportData)); |
|
|
|
downloadItem.setAttribute("download", fileName); |
|
|
|