{ "info": { "author": "Nando Florestan", "author_email": "nandoflorestan@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", "Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: Text Processing :: Markup :: HTML", "Topic :: Text Processing :: Markup :: XML" ], "description": "Kajiki provides fast well-formed XML templates\n==============================================\n\nBecause Kajiki's input is XML, it can ensure that your HTML/XML output is\nwell-formed. The Genshi-like syntax, based on XML attributes or tags, is simply\nbeautiful and easily understood (or ignored) by web designers.\nBut instead of the slow performance of Genshi_, Kajiki compiles\ntemplates to Python code that renders with blazing-fast speed, so Kajiki can\ncompete with the speed of Jinja_, Mako_, Chameleon_ and others.\nAlso, one of Genshi's misfeatures -- py:match -- is replaced with blocks which\nwork like Jinja's blocks.\n\nBy combining the best ideas out there -- XML input,\nGenshi's syntax and features, Jinja's template inheritance and final\ncompilation to Python --, Kajiki is ready to become\nthe most widely used templating engine for web development in Python.\nAnd more features are coming soon; stay tuned!\n\nExample\n=======\n\n.. code:: python\n\n >>> import kajiki\n >>> Template = kajiki.XMLTemplate('''\n ... $title\n ... \n ...

$title

\n ... \n ... \n ... ''')\n >>> print(Template(dict(title='Kajiki is teh awesome!', repetitions=3)).render())\n \n Kajiki is teh awesome!\n \n

Kajiki is teh awesome!

\n \n \n \n\n\nLinks\n=====\n\nDocumentation_\n\nKajiki is licensed under an MIT-style license_.\n\nThe git repository and `issue tracker`_ are at GitHub_. Previously the project\nused SourceForge_ for the hg repository, issue tracker and forums.\n\nWe use Travis_ for continuous integration.\n\n\n.. _Documentation: http://kajiki.readthedocs.org/\n.. _license: https://github.com/nandoflorestan/kajiki/blob/master/LICENSE.rst\n.. _`issue tracker`: https://github.com/nandoflorestan/kajiki/issues\n.. _GitHub: https://github.com/nandoflorestan/kajiki\n.. _SourceForge: http://sourceforge.net/p/kajiki/\n.. _Travis: https://travis-ci.org/nandoflorestan/kajiki\n.. _Genshi: https://pypi.python.org/pypi/Genshi\n.. _Jinja: https://pypi.python.org/pypi/Jinja2\n.. _Mako: https://pypi.python.org/pypi/Mako\n.. _Chameleon: https://pypi.python.org/pypi/Chameleon\n\nCHANGES\n=======\n\n0.8.1 (2019-10-20)\n------------------\n\n* Fixed unexpected when including templates\n\n0.8.0 (2019-06-03)\n------------------\n\n* Fixed support for Python 3.8\n* Dropped support for Python 2.6 and 3.3\n\n0.7.2 (2018-04-16)\n------------------\n\n* Improve parsing of ``${}`` expressions and fix syntax errors reporting in braced expressions.\n* Improve parsing of documents with comments before the root element\n\n0.7.1 (2017-09-11)\n------------------\n\n* Allow to replace ``gettext`` function by providing it in the template context or through ``base_globals`` in Loader\n\n0.7.0 (2017-06-27)\n------------------\n\n* Text for i18n is now extracted ignoring the empty spaces surrounding the text itself. Empty text will always be treated as non translatable nodes for performance reasons.\n* ``extract_python`` option will now report syntax errors when extracting text for translation.\n\n0.6.3 (2017-05-25)\n------------------\n\n* Added ``extract_python`` option to babel message extractor, this allows extracting gettext calls in ``${}`` expressions\n\n0.6.1 (2016-11-28)\n------------------\n\n* Actually report 0.6 in kajiki/version.py\n* Expose ``strip_text`` option in loader\n\n0.6.0 (2016-11-27)\n------------------\n\n* Fixed ``py:switch`` error message wrongly mentioning ``py:with``\n* Support for multiline ``${}`` expressions\n* Subsequent text nodes are now squashed into a single text node. This allows translating whole paragraphs instead of single sentences.\n* Allow code and function calls inside tag attributes\n* Added ``strip_text`` option to XMLTemplate and i18n collector to ensure leading and trailing spaces are stipped by text nodes (also leads to minified HTML)\n* Some HTML nodes that do not require being closed but is commonly considered best practice to close them are now emitted with ending tag (IE:

)\n* Generally improved code documentation to lower entry barrier for contributors\n\n\n0.5.5 (2016-06-08)\n------------------\n\n* ``py:attrs`` will now emit the attribute name itself or will omit the attribute at all in case of\n ``bool`` values for 'checked', 'disabled', 'readonly', 'multiple', 'selected', 'nohref',\n 'ismap', 'declare' and 'defer',\n\n0.5.4 (2016-06-04)\n------------------\n\n* ``py:switch`` now correctly supports multiple ``py:case`` statements.\n* text inside ``