Skip to content

downloadUsingAnchor()

Triggers a file download by creating and clicking a temporary anchor element.

Example:

ts
downloadUsingAnchor('/report.pdf', 'report.pdf');

Released under the MIT License.