README
parcel-plugin-marked-prismjs
Parcel plugin for easily integrating with prismjs plugins by custom marked renderer, feel free to fork this repository and make your own renderer for prismjs.
Installation
npm i -D parcel-plugin-marked-prismjs
# via yarn
yarn add -D parcel-plugin-marked-prismjs
Features
0. match braces
Support vscode extension Bracket Pair Colorizer
like rainbow highlight.
1. heading anchors
## Subtitle With Anchor
will transpile to:
<h2>
<a
name="subtitle-with-anchor"
class="anchor"
href="#subtitle-with-anchor"
></a>
Subtitle With Anchor
</h2>
2. line highlight
Use {}
for supporting code editor syntax highlight.
```js{4,10}
window.confidence = true
const dev = {
confidence: false,
success() {
return this.confidence
},
}
console.log((0, dev.success)()) // true
```
3. diff highlight
```diff-js
- delete dev.confidence
+ const { confidence, ...$dev } = dev
+ dev = $dev
```
Besides, codespan ought to be styled by class .codespan
.