Skip to content

Instantly share code, notes, and snippets.

@joequery
Created December 16, 2012 02:41
Show Gist options
  • Select an option

  • Save joequery/4302637 to your computer and use it in GitHub Desktop.

Select an option

Save joequery/4302637 to your computer and use it in GitHub Desktop.
/* myfile.c */
#include<stdio.h>
/* template.html */
<pre>{% include "myfile.c" %}</pre>
The < and >'s won't be escaped, breaking the html in the template.
/* ideal scenaro */
{% include "myfile.c" %}
The indentation of the include call is applied to each line of myfile.c. This way,
Flask-markdown detects the indentation and uses applies its escape to them.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment