From 997d9763afcfe307455a4666e8bc002f044c5522 Mon Sep 17 00:00:00 2001 From: tunntun Date: Thu, 10 Oct 2024 20:02:37 +0300 Subject: [PATCH] publish npm package --- README.md | 2 +- merkleTree.js => index.js | 0 merkleTree.test.js => index.test.js | 2 +- package.json | 13 ++++++++----- 4 files changed, 10 insertions(+), 7 deletions(-) rename merkleTree.js => index.js (100%) rename merkleTree.test.js => index.test.js (98%) diff --git a/README.md b/README.md index 4342dd3..d4eeb59 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ A JavaScript library to generate a Merkle Tree using SHA-256. The library is des ```javascript const leaves = ['leaf_1', 'leaf_2', 'leaf_3']; -const merkleTree = generateMerkleTree(leaves, (err, merkleTree) => { +generateMerkleTree(leaves, (err, merkleTree) => { if (err) return console.log(err); diff --git a/merkleTree.js b/index.js similarity index 100% rename from merkleTree.js rename to index.js diff --git a/merkleTree.test.js b/index.test.js similarity index 98% rename from merkleTree.test.js rename to index.test.js index 3d752b5..c902443 100644 --- a/merkleTree.test.js +++ b/index.test.js @@ -1,4 +1,4 @@ -const merkleTree = require('./merkleTree'); +const merkleTree = require('./index'); describe.each([ { diff --git a/package.json b/package.json index f390e76..6126440 100644 --- a/package.json +++ b/package.json @@ -1,15 +1,18 @@ { - "name": "merkle-tree", - "version": "1.0.0", + "name": "@node101/merkle-tree", + "version": "0.0.3", "description": "", - "main": "merkleTree.js", + "main": "index.js", "scripts": { - "test": "jest --coverage" + "test": "jest" }, "keywords": [], - "author": "", + "author": "node101", "license": "ISC", "devDependencies": { "jest": "^29.7.0" + }, + "publishConfig": { + "access": "public" } }