utilium 2.3.12 → 2.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/dom.d.ts CHANGED
@@ -6,7 +6,7 @@ export declare function upload(type?: string, multiple?: boolean): Promise<File>
6
6
  /**
7
7
  * Downloads some data
8
8
  */
9
- export declare function download(data: BlobPart, name: string): void;
9
+ export declare function download(name: string, ...parts: BlobPart[]): void;
10
10
  /**
11
11
  * Create an instance of a `<template>`
12
12
  */
package/dist/dom.js CHANGED
@@ -21,9 +21,9 @@ export function upload(type, multiple = false) {
21
21
  /**
22
22
  * Downloads some data
23
23
  */
24
- export function download(data, name) {
24
+ export function download(name, ...parts) {
25
25
  const link = document.createElement('a');
26
- link.href = URL.createObjectURL(new Blob([data]));
26
+ link.href = URL.createObjectURL(new Blob(parts));
27
27
  link.download = name;
28
28
  link.click();
29
29
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "utilium",
3
- "version": "2.3.12",
3
+ "version": "2.4.0",
4
4
  "description": "Typescript utilities",
5
5
  "funding": {
6
6
  "type": "individual",