【发布时间】:2019-12-13 01:10:28
【问题描述】:
我想通过 api web share 共享一个 csv 文件,但我不想使用教程演示中的上传文件,而是使用生成的文件,类似于 this question 中所做的。
我正在做的是
navigator.share({
files: [new Blob([data], {type: type})],
title: 'Vacation Pictures',
text: 'Photos from September 27 to October 14.',
})
.then(() => console.log('Share was successful.'))
.catch((error) => console.log('Sharing failed', error));
【问题讨论】:
标签: javascript html share