]> git.ipfire.org Git - thirdparty/jinja.git/commitdiff
document SandboxedNativeEnvironment pattern 2063/head
authorDavid Lord <davidism@gmail.com>
Fri, 20 Dec 2024 15:57:11 +0000 (07:57 -0800)
committerDavid Lord <davidism@gmail.com>
Fri, 20 Dec 2024 15:57:11 +0000 (07:57 -0800)
docs/nativetypes.rst

index 1a08700b08124791b69ccc1e40f6e0a1499dfbd4..fb2a76718a523febca85ed3a9e12f17c0a706645 100644 (file)
@@ -55,6 +55,17 @@ Foo
 >>> print(result.value)
 15
 
+Sandboxed Native Environment
+----------------------------
+
+You can combine :class:`.SandboxedEnvironment` and :class:`NativeEnvironment` to
+get both behaviors.
+
+.. code-block:: python
+
+    class SandboxedNativeEnvironment(SandboxedEnvironment, NativeEnvironment):
+        pass
+
 API
 ---