[www] Initial Fake Parsing Documents from Markdown. Added documents to Article
This commit is contained in:
1 parent
2630dfd1a2
commit
14954c2b71
3 files changed
+22
-12
No files matched your search
@@ -19,12 +19,14 @@ def markdown_to_html(text):
|
||||
])
|
||||
|
||||
|
||||
def get_images_src(text: str) -> [str]:
|
||||
def extract_files(text: str) -> [str]:
|
||||
html = markdown(text)
|
||||
post_html = lxml.html.fromstring(html)
|
||||
|
||||
images = post_html.cssselect('img')
|
||||
return [img.get('src') for img in images]
|
||||
images = [img.get('src') for img in images]
|
||||
|
||||
return images, []
|
||||
|
||||
|
||||
def create_tree(text: str) -> str:
|
||||
|
||||
Reference in new issue
Block a user