Edgewall Software

Changes between Version 2 and Version 3 of TracDev/PortingFromGenshiToJinja


Ignore:
Timestamp:
Feb 21, 2016, 6:10:23 PM (8 years ago)
Author:
Christian Boos
Comment:

well, #!html was used on purpose in this very specific example (see also PortingFromClearSilverToGenshi#Examples)

Legend:

Unmodified
Added
Removed
Modified
  • TracDev/PortingFromGenshiToJinja

    v2 v3  
    310310</html>
    311311   }}}
    312  - Jinja [source:cboos.git/templates/jindex.html@jinja2 jindex.html]:
     312 - Jinja [source:cboos.git/trac/templates/jindex.html@jinja2 jindex.html]:
    313313   {{{#!html+jinja
    314314<!DOCTYPE html>
     
    341341[source:trac/templates/jdiff_form.html@jinja2 jdiff_form.html], another small template.
    342342
    343 Note that a Jinja2 template can usually be rendered directly to have a taste of how it will look like:
    344 ----
    345 {{{#!html+jinja
     343Note that a Jinja2 .html template can usually be rendered directly in the browser, to have a rough taste of how it will look like:
     344{{{#!div style="border: 1px solid #999; margin: 1em"
     345{{{#!html  (html mode on purpose here!)
    346346    <h1>${_("Available Projects")}</h1>
    347347    <ul>
     
    359359    </ul>
    360360}}}
    361 ----
     361}}}
    362362Though there's no absolutely no constraints on a Jinja2 template, it helps to have an .xml or .html template be  itself '''a well-formed XML document'''.
    363363