diff --git a/web/src/jsMain/kotlin/dev/inmo/kmppscriptbuilder/web/main.kt b/web/src/jsMain/kotlin/dev/inmo/kmppscriptbuilder/web/main.kt index 36e52f8..84880d2 100644 --- a/web/src/jsMain/kotlin/dev/inmo/kmppscriptbuilder/web/main.kt +++ b/web/src/jsMain/kotlin/dev/inmo/kmppscriptbuilder/web/main.kt @@ -14,12 +14,11 @@ fun saveFile(content: String, filename: String) { setAttribute("style", "visibility:hidden; display: none") } as HTMLAnchorElement val blob = Blob(arrayOf(content), BlobPropertyBag( - "text/plain;charset=utf-8" + "application/*;charset=utf-8" )) val url = URL.createObjectURL(blob) a.href = url a.download = filename - a.target = "_blank" a.click() URL.revokeObjectURL(url) a.remove()