More advanced comment/documentation DSL, documentation generation #100
Labels
enhancement
New feature or request
future
Not urgent
improvement
Similar to enhancement, but there is already code which addresses this that must be improved
First of all, I think all the hard work should be done in Novika or Crystal, not in JS as is currently the case. The
json-docs.nk
script simply generates a shit ton of{ "name": "...", "desc": "..." }
objects, which then get processed in several steps by JS. The processing extracts stack argument names etc.There are three big problems with all of this.
comment:...
words in thecomment
capability, enabled by default (for instancecomment:arguments
could leave arguments[ [ '<short-name>' '<long-name>' ] [ ... ] [ ... ] ]
)x y newPoint
word that leaves a point object for the X and Y coordinate. Even if you write the docs on the blocknewPoint
leaves, these docs are only going to be visible at runtime, not at doc collection time.crystal docs
.Now to outline the solutions:
::markName::
(::point::
in ournewPoint
example) creates a "link". Think of it like holes in the code linked by wires. Saying that the effect ofnewPoint
is( X Y -- ::point:: )
means that it leaves the point block, i.e. the block whose comment is::point::
-- and nothing else besides that, at least for now. Let's not over-complicate things. Each word interested in being documented should also say the following in its comment:::point/<name-of-word>::
. The UI should then show a link or an expansion of sorts with documentation for the block. See the code snippet at the very bottom for an example.novika docs
,docs
being an app found inenv
Finally, the UI should be redesigned. It's too plastic-looking.
The text was updated successfully, but these errors were encountered: