aboutsummaryrefslogtreecommitdiff
path: root/src/cmark.c
blob: 16817b968d315c6136ce7c400848a3b609605612 (plain)
  1. #include <stdlib.h>
  2. #include <assert.h>
  3. #include <stdio.h>
  4. #include "node.h"
  5. #include "houdini.h"
  6. #include "cmark.h"
  7. #include "buffer.h"
  8. char *cmark_markdown_to_html(const char *text, int len)
  9. {
  10. cmark_node *doc;
  11. char *result;
  12. doc = cmark_parse_document(text, len);
  13. result = cmark_render_html(doc);
  14. cmark_node_free(doc);
  15. return result;
  16. }