docsify/docs/de-de/markdown.md
Johannes Rappen 73a38c3878 chore: update german docs, fix links (#560)
* updated german links
* fixed links where `QingWei-Li` should've been `docsifyjs`
  * naturally excluded donate links and links to private projects like `vuep` unrelated to docsify

---

See commit for details. If you have a question, just ask.
2018-07-01 13:48:44 +08:00

1.2 KiB

Markdown Einstellungen

docsify verwendet marked, um Markdown umzuwandeln. Du kannst einstellen, wie es deine Markdown Seiten in HTML umwandelt, indem du renderer konfigurierst:

window.$docsify = {
  markdown: {
    smartypants: true,
    renderer: {
      link: function() {
        // ...
      }
    }
  }
}

?> Für mögliche Einstellungen, siehe marked Dokumentation

Du kannst die Regeln auch beliebig anpassen.

window.$docsify = {
  markdown: function(marked, renderer) {
    // ...

    return marked
  }
}

mermaid Unterstützung

// Importiere mermaid
//  <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.css">
//  <script src="//cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js"></script>

mermaid.initialize({ startOnLoad: false });

window.$docsify = {
  markdown: {
    renderer: {
      code: function(code, lang) {
        if (lang === "mermaid") {
          return (
            '<div class="mermaid">' + mermaid.render(lang, code) + "</div>"
          );
        }
        return this.origin.code.apply(this, arguments);
      }
    }
  }
}