Add functions to read markdown
This commit is contained in:
parent
6d56410621
commit
4f5787c96e
1 changed files with 11 additions and 1 deletions
|
@ -31,7 +31,9 @@
|
|||
:build-str-class
|
||||
:build-str-id
|
||||
:validate-date-string-p
|
||||
:*use-cdn*))
|
||||
:*use-cdn*
|
||||
:md-to-html-string
|
||||
:md-file-to-html-string))
|
||||
|
||||
(in-package :ml-sbt)
|
||||
|
||||
|
@ -265,3 +267,11 @@ Returns:
|
|||
(build-str-name name)
|
||||
"-"
|
||||
(remove-special-chars (build-str-value-prop value))))
|
||||
|
||||
(defun md-to-html-string (markdown-string)
|
||||
(with-output-to-string (s)
|
||||
(3bmd:parse-string-and-print-to-stream markdown-string s)))
|
||||
|
||||
(defun md-file-to-html-string (input-file)
|
||||
(with-output-to-string (s)
|
||||
(3bmd:parse-and-print-to-stream input-file s)))
|
||||
|
|
Loading…
Add table
Reference in a new issue