Add a "stripped" argument to {% definevar %}.

Review Request #9050 — Created July 4, 2017 and submitted

chipx86
Djblets
release-0.10.x
a910411...
djblets

The new "stripped" argument allows for more expressive multi-line values
passed to {% definevar %} without worrying about the leading or
trailing whitespace that would occur. The argument will strip away the
whitespace before storing the value in the context.

This required a new resolve_vars option to the @blocktag decorator,
which controls whether the arguments passed to the template tag function
will be automatically resolved as variables. By default, they continue
to be resolved, but this behavior can now be turned off.

Unit tests pass.

  • 0
  • 0
  • 2
  • 0
  • 2
Description From Last Updated
brennie
  1. 
      
  2. This line is not necessary IMO.

  3. 
      
david
  1. 
      
  2. Single quotes?

  3. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-0.10.x (77280e4)
Loading...