Markdown Not Interpreted When Pulled from Page w/ Embedded Discussion

Please correct me if I am wrong, but it seems to me that markdown is not being interpreted when topics are generated via the embedded discussions feature.

This is a generated topic from the following page: Tobin: The Clueless One | Fire Emblem Heroes | KageroChart

I have configured Discourse to pull the contents of #copyme, which it does. However, the copied text is displaying literally.

As you can see in the screenshot, when I click the edit button, the preview is correct. If I make an update to the post, the markdown is interpreted.

Thanks

1 Like

This is not a bug but a feature request.

Currently we are assuming that the embedded content will be HTML, so the cook_method is set to raw_html as per this code.

The better solution here is to add a new site setting to control cook_method for embedded topics.

#pr-welcome

4 Likes

This was because when editing a post we were ignoring cook_method , @gerhard recently fixed this via:

https://github.com/discourse/discourse/commit/4205c1ad2bcbd2572fb4b7eb37c641a4c4db5cec

So now when editing the embedded topic the markdown will not work, which seems like a bug to me.

I have added this to my priority list since there is no workaround now except to edit a post in HTML format, which is not convenient.

6 Likes

Done via:

https://github.com/discourse/discourse/commit/12706c4b295d260bbf34f5a8afc7e31971b3ea45

There is a new site setting embed support markdown (default off), if enabled the rendering will be same as what we have for topics created on Discourse composer.

6 Likes