Skip to content

Conversation

@code-monad
Copy link
Owner

This pull request introduces new functionality for retrieving and saving file content from the blockchain, along with some minor updates to the package.json and src/index.ts files. The main changes include the addition of utility functions and the necessary updates to import and export statements.

New functionality:

  • Added getFileContentFromChain function to retrieve complete file content from the blockchain by following backlinks.
  • Added saveFileFromChain function to save file content retrieved from the blockchain to disk.
  • Introduced safelyDecode utility function to safely decode buffer to string, handling errors gracefully.

Updates to import/export statements:

  • Updated src/index.ts to include new imports for getFileContentFromChain and saveFileFromChain. [1] [2]

Minor changes:

  • Added a new script example:retrieve in package.json to run the new functionality examples.
@code-monad code-monad merged commit ef7c91d into master Mar 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant