dataUrlToFile

See source code

Converts a data URL to a file.

function dataUrlToFile(
  url: string,
  filename: string,
  mimeType: string,
): Promise<File>;

Parameters

NameDescription

url

string;

The data URL to convert.

filename

string;

The name of the file.

mimeType

string;

The MIME type of the file.

Returns

Promise<File>;

A promise that resolves to a file.

Prev
createTLStore
Next
DefaultBackground