Login  Register

Re: AsciiDoctor's content strategy

Posted by mojavelinux on May 25, 2013; 12:51am
URL: https://discuss.asciidoctor.org/AsciiDoctor-s-content-strategy-tp237p239.html

I want to also add that one of the most brilliant, forward-thinking features of AsciiDoc is the block role (or style). This feature, which is only seen in one other lightweight markup language (reStructuredText), enables you to identify paragraphs or blocks of content for use in different contexts.

For example, to define an abstract:

[abstract]
A chunk of content that can be used where the abstract of the content needs to be displayed.

The abstract is a built-in role (called a style). When a built-in role is not available, a role can be used to pass the same type of information:

[role="feature-list"]
* lightweight
* reusable
* readable
* etc...

And not only can a role be assigned to a single paragraph, block or list, it can also be assigned to a sequence of content thanks to the open block.

[role="lead"]
--
Opening paragraph of the lead.

Another lead paragraph.

* topic 1
* topic 2
* topic 3

Conclusion of the lead.
--

This allows AsciiDoc to fully satisfy the requirements of journalism. It could absolutely be used as *the* storage format for content submissions to any news organization, (true) CMS or even a call for papers.

-Dan