Skip to main content

django-orgco implements a template tag to use orgco easily in django templates

Project description

https://travis-ci.org/paetzke/django-orgco.png?branch=master https://coveralls.io/repos/paetzke/django-orgco/badge.png?branch=master

Copyright (c) 2013, Friedrich Paetzke (f.paetzke@gmail.com) All rights reserved.

django-orgco implements a template tag to use orgco easily in django templates.

How to use

Install the package via pip

$ pip install django-orgco

Add the package to your installed apps in settings.py.

INSTALLED_APPS = (
    ...
    'django_orgco',
    ...
)

Then use it. Here is an example:

my_template.html:

{% load orgdoc %}

{% orgdoc %}
* header is here

- short1 :: long1
- short2 :: long2
- short3 :: long3

| th1 | th2 |
|-----+-----|
| td1 | td2 |
{% endorgdoc %}

To enable code highlighting add highlight to orgdoc:

{% orgdoc highlight %}
is_ok = True
{% endorgdoc %}

The tag does not produce safe output by default. You have to mark it as safe yourself:

{% load orgdoc %}
{% orgdoc highlight %}
{{ code|safe }}
{% endorgdoc %}
https://d2weczhvl823v0.cloudfront.net/paetzke/django-orgco/trend.png

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-orgco-0.0.4.tar.gz (3.1 kB view hashes)

Uploaded source

Built Distribution

django_orgco-0.0.4-py2.py3-none-any.whl (4.2 kB view hashes)

Uploaded 2 7

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page