Skip to content

StephenHesperus/remark-hook

Repository files navigation

Remark Hook

This project is a hook runs after the remark.js to provide highlighting in fenced code blocks.

The original project: remark.js. remark.js is a fascinating tool to create presentation using an enhanced version of markdown, go and check it out.

Features

Tile View Mode (New Feature)

Tile view mode shows all slides of a slide show. Click on a slide, the slide show will go on from that slide. Use keyboard 'T' to toggle between tile view mode and play mode.

Highlight in Code Blocks

1. highlighting a whole line

Just change the first character of the line to !.

```python
def say_hello():
!   print('Hello, world!');
```

It will display as (the highlighted style can be customized):

def say_hello():
    print('Hello, world!');

2. highlighting tokens

Use this format: `highlighted tokens`.

```python
`def` say_hello():
    print(`'Hello, world!', continued_highlight`);
```

It will display as:

def say_hello():
    print('Hello, world!', continued_highlight)

3. escaped back-quotes

Use this format: \`escaped back-quotes\`.

4. customize highlighting style

  • highlighted lines Define rules for the class remark-code-line-highlighted.

  • highlighted tokens Define rules for the class remark-code-token-highlighted.

About

Hooks runs after remark.js to provide more functions.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published