markdown tamplate
refactoring code