asciidoctor-shiki 1.0.0
Install from the command line:
Learn more about npm packages
$ npm install @ink-feather-org/asciidoctor-shiki@1.0.0
Install via package.json:
"@ink-feather-org/asciidoctor-shiki": "1.0.0"
About this version
This extension is available on npmjs.com
$ node install @ink-feather-org/asciidoctor-shiki
This extension is not designed for browser. You must not use this extension without Node.js.
import adoc from '@asciidoctor/core'
import { AsciidoctorShiki } from '@ink-feather-org/asciidoctor-shiki'
const asciidoctor = adoc()
asciidoctor.SyntaxHighlighter.register('shiki', AsciidoctorShiki)
const options = {
attributes: {
'source-highlighter': 'shiki',
'shiki-theme': 'nord'
}
}
const document = `
[source,ruby]
----
p "Hello"
----
`;
console.log(asciidoctor.convert(document, options))
- Register this extension using
SyntaxHighlighter.register
- Set the attribute
source-highlighter
- Set the attribute
shiki-theme
Copyright (c) 2022 TANIGUCHI Masaya. All rights reserved.
This extension is licensed under the MIT license https://git.io/mit-license
Details
- asciidoctor-shiki
- ink-feather-org
- over 2 years ago
- MIT
- 8 dependencies
Assets
- asciidoctor-shiki-1.0.0-npm.tgz
Download activity
- Total downloads 0
- Last 30 days 0
- Last week 0
- Today 0