Ask AI
Skip to main content

Convert html to markdown

Function: Convert HTML to Markdown

This function allows you to easily transform content written in HTML format into Markdown format. Markdown is a lightweight markup language that is often used for creating formatted text using a plain text editor. This is useful for tasks like preparing content for blogs, documentation, or simple web pages where you prefer the simplicity of Markdown over the complexity of HTML.

Input

  • The HTML you wish to convert (Type: STRING) The actual HTML content (a piece of text) that you want to convert into Markdown. For example, <h1>My Title</h1><p>Some text.</p>.

Output

  • Output (Type: STRING) This is the name of the variable where the converted Markdown text will be stored. By default, this variable will be named MARKDOWN, but you can choose a different name if you prefer. The value stored in this variable will be the Markdown representation of your input HTML.

Execution Flow

Real-Life Examples

Here are a few examples of how you might use the "Convert HTML to Markdown" function:

Example 1: Converting a simple blog post snippet

  • Inputs:
    • The HTML you wish to convert: <h2>Welcome!</h2><p>This is a <strong>new</strong> blog post about <em>no-code</em> platforms.</p>
    • Output variable name: BlogPostMarkdown
  • Result: The application will convert the HTML, and a new variable named BlogPostMarkdown will be created, containing the following Markdown text:
    ## Welcome!

    This is a **new** blog post about *no-code* platforms.

Example 2: Preparing content for a documentation page

  • Inputs:
    • The HTML you wish to convert: <p>To get started, click the <a href="/setup">Setup</a> button.</p><ul><li>Step 1: Login</li><li>Step 2: Configure</li></ul>
    • Output variable name: (Using default) MARKDOWN
  • Result: The application will convert the HTML, and the MARKDOWN variable will be updated with the following content:
    To get started, click the [Setup]\(/setup\) button.

    * Step 1: Login
    * Step 2: Configure

Example 3: Cleaning up email content for internal notes

  • Inputs:
    • The HTML you wish to convert: <div><p>Hi Team,</p><p>The meeting is rescheduled to <b>Friday</b> at <i>3 PM</i>.</p><p>Thanks,<br>John</p></div>
    • Output variable name: MeetingNotes
  • Result: The application will convert the HTML, and the MeetingNotes variable will contain the simplified Markdown:
    Hi Team,

    The meeting is rescheduled to **Friday** at *3 PM*.

    Thanks,
    John