Blank contract.

This commit is contained in:
ravinsp
2022-08-21 15:47:49 +05:30
parent e282484c60
commit 7e2ec90542
3 changed files with 27 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
{
"contract": {
"bin_path": "/usr/bin/node",
"bin_args": "index.js"
}
}

View File

@@ -0,0 +1,12 @@
{
"name": "_projname_",
"version": "1.0.0",
"scripts": {
"build": "npx ncc build src/_projname_.js -o dist",
"start": "npm run build && hpdevkit deploy dist"
},
"dependencies": {
"hotpocket-nodejs-contract": "0.5.6",
"@vercel/ncc": "0.34.0"
}
}

View File

@@ -0,0 +1,9 @@
const HotPocket = require("hotpocket-nodejs-contract");
const _projname_ = async (ctx) => {
// Your smart contract logic.
console.log('Blank contract');
}
const hpc = new HotPocket.Contract();
hpc.init(_projname_);