anyconfig.template¶
Misc global constants, variables, classes and so on.
- anyconfig.template.try_render(filepath=None, content=None, **options)¶
Compile and render template and return the result as a string.
- Parameters:
filepath (
str|None) – Absolute or relative path to the template filecontent (
str|None) – Template content (str)options (
Any) – Keyword options passed torender()defined above.
- Return type:
str|None- Returns:
Compiled result (str) or None