tag:support.markedapp.com,2011-09-11:/discussions/questions/9000-is-there-a-way-to-have-a-conditional-block-inside-markedMarked: Discussion 2017-08-24T23:33:03Ztag:support.markedapp.com,2011-09-11:Comment/432764272017-08-23T21:27:07Z2017-08-23T21:27:07ZIs there a way to have a conditional block inside Marked<div><p>Based on what conditions?</p>
<p>-- Brett Terpstra</p></div>Bretttag:support.markedapp.com,2011-09-11:Comment/432764272017-08-23T22:22:02Z2017-08-23T22:22:02ZIs there a way to have a conditional block inside Marked<div><p>So, I was thinking that I have multiple resumes right now which I am targeting to different people and I would really like an ifdef type mechanism so I can say for example </p>
<p>#define EDUCATIONAL_PRODUCT </p>
<p>on top and then inside the markdown doc I can say</p>
<p>#ifdef EDUCATIONAL_PRODUCT * Product manager for this awesome product #endif</p>
<p>and then certain things will be included and not others. </p>
<p>Regards</p>
<p>Amit</p>
<p>PS: please dont post the above on the forum. </p>
<p>A</p></div>Amit Agrawaltag:support.markedapp.com,2011-09-11:Comment/432764272017-08-24T14:26:24Z2017-08-24T14:26:24ZIs there a way to have a conditional block inside Marked<div><p>This is the kind of thing that you'd want to use a custom pre-processor for. A simple script that read in keys at the top and then removed parts conditionally would be pretty easy to set up. Pre-processors run before rendering, and it's designed to allow manipulation of the text before it reaches the Markdown processor.</p>
<p><a href="http://marked2app.com/help/Custom_Processor.html#preprocessor">http://marked2app.com/help/Custom_Processor.html#preprocessor</a></p></div>Bretttag:support.markedapp.com,2011-09-11:Comment/432764272017-08-24T23:33:03Z2017-08-24T23:33:03ZIs there a way to have a conditional block inside Marked<div><p>Thank you. This will work well. </p>
<p>Regards</p>
<p>Amit</p></div>Amit Agrawal