fixes to render markdown correctly