Skip to main content
April 10, 2025
Solved

Saving data to a file on a local laptop

  • April 10, 2025
  • 3 replies
  • 75 views

Hello, I am currently facing a problem exporting some custom data to a file on my laptop.

The data is properties from Custom data represented in Yaml format converted to a string. I’m trying to save it by clicking my extension in context MenuType created with client.registerAction.

Normally, I use fs.writeFile on my server side and post method on my client side. Now I'm a little confused on how to do this with Lucid.

I would appreciate any help.

Best answer by Alex L

Hi Darina, currently Lucid only allows for direct download to your browser’s default directory. Choosing the location would have be configured in the user’s browser.

Comments

April 10, 2025

Oh, I just found the client.download method. But is there a way to save the file to a specific directory?

Alex LAnswer
Lucid product team
April 10, 2025

Hi Darina, currently Lucid only allows for direct download to your browser’s default directory. Choosing the location would have be configured in the user’s browser.

April 11, 2025

Thank you ​@Alex L