-
-
Notifications
You must be signed in to change notification settings - Fork 389
format
Tells ReSpec to treat the document as being in a format other than HTML. Supported formats:
- "markdown"
- Interpreted as GitHub flavored markdown
var respecConfig = {
format: "markdown",
}
When format
is set to "markdown", you can use a mix of HTML and markdown:
## Using markdown
This will be a paragraph.
<pre class="example" title="A markdown example">
function thisIsNice(){
becauseWeCanUseMarkdown();
}
// And using markdown is pretty sweet!
const foo = "FOO";
while(foo){
Promise.all([...lotsOfPromises])
}
</pre>
ReSpec will detect minimum common indentation and deduct them so that indented texts won't be consider as code blocks.
<body>
# This is indented markdown
Since the minimum common indentation is 2, ReSpec will deduct them before parsing
Indented code block
</body>
Please remember that markdown requires double newlines between an HTML tag and markdown text - but we do support single newline.
<section>
## Markdown inside HTML tags
This is the correct way to insert markdown inside HTML.
</section>
<section>
## Markdown inside HTML tags
This is supported for backward compatibility sake.
</section>
See also: nolink
class to disable automatic linking in code blocks, if needed.
In some cases, the markdown processor gets confused. For example, given:
<pre class="example">
1 * 2 * 3;
</pre>
The "*
"s get converted to an <em>
. Obviously, that's not ideal. A workaround is to wrap the "*" in back-ticks, like this:
<pre class="example">
1 `*` 2 `*` 3;
</pre>
💖 Support ReSpec by becoming a sponsor via Open Collective. 💖
✨ View rendered version of this documentation at https://respec.org/docs/ ✨
- addSectionLinks
- authors
- caniuse
- edDraftURI
- editors
- favicon
- format (markdown)
- formerEditors
- github
- highlightVars
- isPreview
- license
- lint
- localBiblio
- logos
- maxTocLevel
- mdn
- modificationDate
- noTOC
- otherLinks
- pluralize
- postProcess
- preProcess
- previousDiffURI
- previousMaturity
- previousPublishDate
- prevRecShortname
- prevRecURI
-
processVersion(Deprecated) - publishDate
-
refNote(Deprecated) - shortName
- specStatus
- subjectPrefix
- subtitle
- testSuiteURI
- xref
- additionalCopyrightHolders
-
addPatentNote(Deprecated) - alternateFormats
- canonicalURI
- charterDisclosureURI
- copyrightStart
- crEnd
-
darkMode(deprecated, use dark mode) - doJsonLd
- errata
- group
- implementationReportURI
- lcEnd
- level
- noRecTrack
- prevED
- submissionCommentNumber
-
wg(Deprecated) -
wgId(Deprecated) -
wgPatentPolicy(Deprecated) -
wgPatentURI(Deprecated) - wgPublicList
-
wgURI(Deprecated)
a11y
check-punctuation
local-refs-exist
no-headingless-sections
no-http-props
no-unused-vars
no-unused-dfns
informative-dfn
privsec-section
wpt-tests-exist
Handled by ReSpec for you.
- data-abbr
-
data-cite(Not recommended) - data-dfn-for
- data-dfn-type
- data-format
- data-include-format
- data-include-replace
- data-include
- data-link-for
- data-link-type
- data-local-lt
- data-lt-no-plural
- data-lt-noDefault
- data-lt
- data-number
- data-oninclude
- data-sort
- data-tests
-
data-transform(Deprecated) - data-type
- dir
- lang