mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-14 15:14:31 -04:00
migrate plugin loading process to new pluggy-powered system based on djp
This commit is contained in:
parent
efd341d8ad
commit
8ed3155ec5
28 changed files with 690 additions and 321 deletions
12
archivebox/abx/hookspec_django_urls.py
Normal file
12
archivebox/abx/hookspec_django_urls.py
Normal file
|
@ -0,0 +1,12 @@
|
|||
from .hookspec import hookspec
|
||||
|
||||
|
||||
@hookspec
|
||||
def get_urlpatterns():
|
||||
return [] # e.g. [path('your_plugin_type/plugin_name/url.py', your_view)]
|
||||
|
||||
@hookspec
|
||||
def register_urlpatterns(urlpatterns):
|
||||
"""Mutate urlpatterns in place to add your urlpatterns in a specific position"""
|
||||
# e.g. urlpatterns.insert(0, path('your_plugin_type/plugin_name/url.py', your_view))
|
||||
pass
|
Loading…
Add table
Add a link
Reference in a new issue