2

I see something I assume to be akin to javadoc at https://www.npmjs.com/package/solidity-doc and Github at https://github.com/vitiko/solidity-doc. However, I see no documentation... the closest I get is a line in Github mentioning /// notation.

Can anyone tell me where this, or anything similar, may be documented? From a quick glance at the code, I'm not finding the relevant info.

2

1 Answer 1

4

What you want is Natspec.

If you want to convert this to a more agreeable format, have a look at "Convert natspec into human readable document".

6
  • Hmm, I installed doxity and tried to build, without actually having Natspec comments in place yet. But I hit a bunch of errors that seem more like bitrot (paths not being created, that sort of thing). Also, parse errors. I wonder if it's kept pace with Solidity.... Commented Mar 2, 2018 at 22:52
  • That's annoying. Does it match any of the most recently reported issues? github.com/DigixGlobal/doxity/issues (Might be worth raising one if not, though looks like the last commit was 6 months ago, so bitrot wouldn't be surprising... ) Commented Mar 3, 2018 at 14:39
  • Unfortunately the errors are entirely uninformative: >⚠️ Error parsing Contract: AbortTest >⚠️ Error parsing Contract: Common >⚠️ Error parsing Contract: Debuggable >⚠️ Error parsing Contract: Econsent >⚠️ Error parsing Contract: Logger >⚠️ Error parsing Contract: Migrations >⚠️ Error parsing Contract: ThrowProxy >⚠️ Error parsing Contract: strings >Generating output for 8 contracts... done! Commented Mar 5, 2018 at 14:59
  • So much for obeying linebreaks :). Anyway, possible the issue is that these use interfaces, and I see issues talking about later solc not being supported. However, it's still useful to put in the @ tags and be ready for doxity if it ever works, and the source is at least documented this way. Commented Mar 5, 2018 at 15:02
  • I hadi no idea whether, after complaining about parsing, I could publish. If I run publish, I get two complaints. One is about a missing node.js build. I don't need it for my Solidity stuff (not yet anyway); I would expect doxity to provide an empty one if it needs it. The other is trying to rename scripts/doxity/public to docs. Commented Mar 5, 2018 at 15:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.