Skip to content

Feature request: Support markdown attributes & custom config #20

@jhon-andrew

Description

@jhon-andrew

You have a nice implementation going on here. 🔥

I hope you could add support for attributes like in this npm package: markdown-it-attrs

So we could do something like this in our .md file

'''html{data-line-numbers=3,8-10}
<table>
  <tr>
    <td>Banana</td>
    <td>$1</td>
    <td>7</td>
  </tr>
  <tr>
    <td>Oranges</td>
    <td>$2</td>
    <td>18</td>
  </tr>
</table>
'''

And render it to something like this:

<pre><code data-line-numbers="3,8-10">
<table>
  <tr>
    <td>Apples</td>
    <td>$1</td>
    <td>7</td>
  </tr>
  <tr>
    <td>Oranges</td>
    <td>$2</td>
    <td>18</td>
  </tr>
</table>
</code></pre>

...the same as in the reveal.js docs.


Additionally, the managing of Reveal.js Config through the Settings UI is a nice touch but it would add more flexibility if you could also support custom config from Settings JSON by updating your Reveal.initialize() to something like this:

const fromSettingsUI = { ... }
const fromSettingsJSON = { ... }

Reveal.initialize({
  ...fromSettingsUI,
  ...fromSettingsJSON, // overwrite everything else that are not configurable through the UI
})

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions