This commit is contained in:
Offray Vladimir Luna Cárdenas 2024-03-10 10:23:14 -05:00
commit 8143633b42
1 changed files with 13 additions and 0 deletions

View File

@ -173,6 +173,19 @@ Markdeep >> extractTitleFrom: docTree [
^ tempTitle
]
{ #category : #accessing }
Markdeep >> extractYamlMetadataFrom: documentTree [
| yamlComment response |
yamlComment := documentTree children
detect: [:node | node className = 'PPCMHtmlBlock' and: [node text trimmed beginsWith: '<!--@yaml']]
ifNone: [ ^ nil ].
response := '' writeStream.
yamlComment children allButFirst allButLast do: [:each |
response nextPutAll: each text; cr
].
^ YAML2JSON fromString: response contents
]
{ #category : #accessing }
Markdeep >> file: aFileReference [
file := aFileReference.