From b4a84dc28e04950dbc63c94b30fda55bd7d0882b Mon Sep 17 00:00:00 2001 From: nprimo Date: Mon, 13 Mar 2023 15:47:28 +0000 Subject: [PATCH] feat(hash-file): update subject Add information on how to export the required function --- subjects/blockchain/hash-file/README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/subjects/blockchain/hash-file/README.md b/subjects/blockchain/hash-file/README.md index d2403e105..44c6320e5 100644 --- a/subjects/blockchain/hash-file/README.md +++ b/subjects/blockchain/hash-file/README.md @@ -4,6 +4,12 @@ Create a function `hashFile(fpath)` that given the name of a file in the current folder, expected to be a string, returns the hash `sha256` of the content of this file as a string. +Here an example on how you should make your function used from external scripts: + +```js +exports.hasFile = ... +``` + ### Usage Here below an example of `main.js` script to test the usage of the `hashFile` function: