Closed nksazonov closed 2 years ago
What version of solidity-docgen do you have installed?
latest, 0.5.16
0.5 doesn't support TypeScript helpers and is no longer actively maintained. You can use 0.6. Keep in mind that it's used differently (it's a Hardhat plugin) see the readme.
Afternoon!
I have stumbled upon some difficulties creating helpers in typescript for handlebars. Hope you will be able to help.
Why: I need to create some typescript handlebars helper to use inside
contract.hbs
.Error: When running
solidity-docgen
I get this error:SyntaxError: Unexpected token 'export'
.Expected: working helper.
helpers.ts
:solidity-docgen
invokation:npx solidity-docgen --solc-module solc -t templates -H templates/helper.ts -i contracts
Nevertheless, if I write that helper in
js
file usingcommonjs
modules, everything works fine.