Defined in: packages/megadoc-corpus/defs/core.js
A document is the "meat" of the Corpus, or its "building block". What a document node may contain is context-specific. For example, in the context of Markdown, a document would be the actual article. Whereas in the context of a programming language, a document could be a class, a module, or a function.
Documents can be nested beneath each other. This is very useful for
representing ancestry chains, like in the case of programming languages that
support namespacing like Ruby (::
), C++ (::
), or even virtual namespaces
as can be achieved in JavaScript comments (e.g. the @namespace
tag).
A document can have entities which are leaf nodes in the tree. Refer to their documentation for more information.
T.Namespace|T.Document
The parent node this node belongs to. You can "nest" documents within each other by attaching a T.Document node to another as its parentNode.
If the parentNode is of type T.Namespace, then it means that this document is a top-level one.
String
Made with ♥ using megadoc.
Contents