dtesler / medium-to-markdown

Converts Medium posts to markdown.
MIT License
111 stars 36 forks source link

[Bug] GitHub Gists from Medium article missing in markdown output #5

Open KaustubhDamania opened 4 years ago

KaustubhDamania commented 4 years ago

I tried converting this Medium article into Markdown. But the Github Gists were missing in the markdown output.


Medium article containing the Gist:

image

The resultant output (with the Gist snippet missing):

image

The script I used:

const mediumToMarkdown = require('medium-to-markdown');
const url = "https://towardsdatascience.com/a-minimalist-end-to-end-scrapy-tutorial-part-ii-b917509b73f7";

mediumToMarkdown.convertFromUrl(url)
.then(function (markdown) {
  console.log(markdown); //=> Markdown content of medium post
});

Possible solution could be to fetch the HTML of the iframe containing the Gist and then enclose them in a code block in the markdown output.

thibaultmol commented 8 months ago

Having this same problem, shame it's not added yet