puvi
May 1, 2024, 11:28am
1
I’m trying to have a button that allows signed-in users to download any data that they query, as a .csv or .json file.
I tried new Blob()
in the Run Code interaction, but I don’t think Plasmic’s js supports the Blob constructor.
I’ve also tried createURIObject, but I’m not sure if I should use that as it’s a lot of rows being queried by users.
I’m using Supabase’s database as integration in Plasmic.
Hello @puvi . You should be able to use new Blob()
, even if it errors in the Run Code interaction. We will be fixing the issue, thanks for reporting it.
1 Like
puvi
May 2, 2024, 6:25am
3
Thanks for replying @icaro_guerra , I just tried it out, but I can’t test it out for certain. Since the page navigation is disabled, I can’t get the downloadable .csv file.
Tried to publish to plasmic hosting to try out the file download, but the whole site is 404 now.
puvi
May 3, 2024, 4:58am
4
Hi @icaro_guerra , using Blob in Run Code works now.
Plasmic doesn’t show an error anymore when using blob in custom expressions.
I’ve created a new project to test out using blob.
There’s button to add data as a blob from a state array to a state object.
My findings :
When Add Data to Blob is clicked in Preview , everything works fine.
When Add Data to Blob is clicked in Interactive Mode Plasmic Studio completely freezes.
It’s not an issue for me at the moment, as using new Blob() now works, however just informing that this issue exists.
Thanks for reporting the issue. We will be looking into it.
1 Like