template tags in django code example
Example 1: template tags in django
from django import template
register = template.Library()
#simle Tag
@register.simple_tag
def fun_name(data):
return data
Example 2: template tags in django
from django import template
register = template.Library()
#simle Tag
@register.simple_tag
def fun_name(data):
return data