(->md {:keys [results]} file-name)
input: :results (coll) from the notion API https://api.notion.com/v1/blocks/<id>/children file-name: the current md file being generated output: an md file with markdown formatted string as content (and other possible md files created)
input: :results (coll) from the notion API https://api.notion.com/v1/blocks/<id>/children file-name: the current md file being generated output: an md file with markdown formatted string as content (and other possible md files created)
(->spaces-affixes text)
(-main & args)
(apply-annotations
{:keys [annotations] :or {annotations no-annotations} :as text-element})
Example: input: 'abc' marked as bold output 'abc' annotations: { bold: false, italic: false, strikethrough: false, underline: false, <-- unsupported code: false, color: default <-- unsupported }
Example: input: 'abc' marked as bold output '*abc*' annotations: { bold: false, italic: false, strikethrough: false, underline: false, <-- unsupported code: false, color: default <-- unsupported }
(apply-space-affixes raw-text processed-text)
Example: raw-text ' abc ' processed-text '~~abc~~' output ' ~~abc~~ '
Example: raw-text ' abc ' processed-text '~~abc~~' output ' ~~abc~~ '
(code->md prefix text language)
(create-readme! secret page-id)
(element->content prefix file-name)
input: prefix (optional) to prepend to md content if nested file-name the current md file-name element: a block from the notion API output: (may create an md files) string with markdown content
input: prefix (optional) to prepend to md content if nested file-name the current md file-name element: a block from the notion API output: (may create an md files) string with markdown content
(element->md results & opts)
input: :results (coll) from the notion API https://api.notion.com/v1/blocks/<id>/children opts: prefix: nil or a prefix file-name: the current md file being generated output: a markdown formatted string (and possible md files created)
input: :results (coll) from the notion API https://api.notion.com/v1/blocks/<id>/children opts: prefix: nil or a prefix file-name: the current md file being generated output: a markdown formatted string (and possible md files created)
(fetch-notion-children id)
(parse-bulleted-list-item prefix)
https://www.markdownguide.org/basic-syntax/#unordered-lists
(parse-child-page! current-file)
Creates a file and returns a link to it
Creates a file and returns a link to it
(parse-code prefix)
returns ```language code;
returns ```language code; ```
(parse-column! prefix file-name)
Returns the children content
Returns the children content
(parse-column-list! prefix file-name)
Returns the children content
Returns the children content
(parse-divider _)
(parse-equation prefix)
(parse-heading heading-key)
See https://developers.notion.com/reference/block heading blocks
See https://developers.notion.com/reference/block heading blocks
(parse-image! {:keys [image]})
Creates a file and returns a file link markdown formatted It assumes it's a png file
Creates a file and returns a file link markdown formatted It assumes it's a png file
(parse-link-to-page! {:keys [link_to_page]})
Returns the content from the page. Doesn't return a markdown link
Returns the content from the page. Doesn't return a markdown link
(parse-numbered_list_item prefix)
https://www.markdownguide.org/basic-syntax/#ordered-lists
(parse-paragraph {:keys [has_children id paragraph]})
Paragraph blocks Paragraph block objects contain the following information within the paragraph property: Property Type Description text array of rich text objects Rich text in the paragraph block. children array of block objects Any nested children blocks of the paragraph block.
Paragraph blocks Paragraph block objects contain the following information within the paragraph property: Property Type Description text array of rich text objects Rich text in the paragraph block. children array of block objects Any nested children blocks of the paragraph block.
(parse-quote prefix)
https://www.markdownguide.org/basic-syntax/#blockquotes-1
(parse-synced-block! {:keys [synced_block has_children id]})
Parses a synced_block, returns it's original content
Parses a synced_block, returns it's original content
(parse-template! {:keys [template has_children id]})
Parses the template type from notion.
Parses the template type from notion.
(parse-text text-element)
input: a https://developers.notion.com/reference/rich-text output: if its a link, [text] (link), else, the text with Markdown surroundings
input: a https://developers.notion.com/reference/rich-text output: if its a link, [text] (link), else, the text with Markdown surroundings
(parse-todo prefix)
A TODO checkbox. If its checked, represent it as markdown
A TODO checkbox. If its checked, represent it as markdown
(parse-toggle! {:keys [toggle has_children id]})
Returns a <details> html element that will be rendered as a button to fold content
Returns a <details> html element that will be rendered as a button to fold content
(parsers kind prefix file-name)
input: type of notion element; optional prefix for recursiveness; current file-name output: (may create an md file) string with markdown content
input: type of notion element; optional prefix for recursiveness; current file-name output: (may create an md file) string with markdown content
(placeholder-parser element)
Parser not supported or not implemented. If there is a text, show it, else dump the element form
Parser not supported or not implemented. If there is a text, show it, else dump the element form
(sort-md-chars coll)
They must be sorted this way to show fine at github
They must be sorted this way to show fine at github
(spaces-prefix text)
Example: input ' abc' output ' '
Example: input ' abc' output ' '
(spaces-suffix text)
Example: input 'abc ' output ' '
Example: input 'abc ' output ' '
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close