Add the items to the instance of the environment if they do not exist yet. This is used by :ref:`extensions <writing-extensions>` to register callbacks and configuration values without breaking inheritance.
(self, **attributes: t.Any)
| 375 | self.extensions.update(load_extensions(self, [extension])) |
| 376 | |
| 377 | def extend(self, **attributes: t.Any) -> None: |
| 378 | """Add the items to the instance of the environment if they do not exist |
| 379 | yet. This is used by :ref:`extensions <writing-extensions>` to register |
| 380 | callbacks and configuration values without breaking inheritance. |
| 381 | """ |
| 382 | for key, value in attributes.items(): |
| 383 | if not hasattr(self, key): |
| 384 | setattr(self, key, value) |
| 385 | |
| 386 | def overlay( |
| 387 | self, |
no test coverage detected