Attributes & Directives
About 103 wordsLess than 1 minute
2026-08-31
Shirone allows attaching attribute dictionaries to Markdown elements to assign custom classes, IDs, or data attributes to the generated HTML markup.
Inline Element Attributes
Attach {} directly after inline elements:
[External Link](https://example.com){target="_blank" rel="noopener"}
==Highlighted text=={.secondary}
`code phrase`{.custom-badge}Block Element Attributes
Declare attributes on block containers or headings:
## Custom Anchor Heading {#custom-section-id}
::: tip[Custom Container]{class="custom-highlight-box"}
Container contents
:::Shorthand Rules
.class-name: Shorthand forclass="class-name"#id-name: Shorthand forid="id-name"key="value": Standard HTML attribute definition
Copyright
Copyright Ownership:matsuzaka-yuki
License under:Attribution 4.0 International (CC-BY-4.0)