mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Uses https://pluggy.readthedocs.io/ originally created for the py.test project We're starting with two plugin hooks: prepare_connection(conn) This is called when a new SQLite connection is created. It can be used to register custom SQL functions. prepare_jinja2_environment(env) This is called with the Jinja2 environment. It can be used to register custom template tags and filters. An example plugin which uses these two hooks can be found at https://github.com/simonw/datasette-plugin-demos or installed using `pip install datasette-plugin-demos` Refs #14
3 lines
146 B
Python
3 lines
146 B
Python
from datasette.version import __version_info__, __version__ # noqa
|
|
from .hookspecs import hookimpl # noqa
|
|
from .hookspecs import hookspec # noqa
|