mirror of https://github.com/searx/searx
[doc] plugin doc update
parent
d2f8d1bfab
commit
407e4b3de5
|
@ -9,6 +9,9 @@ name = 'Example plugin'
|
|||
description = 'This plugin extends the suggestions with the word "example"'
|
||||
default_on = False # disable by default
|
||||
|
||||
js_dependencies = tuple() # optional, list of static js files
|
||||
css_dependencies = tuple() # optional, list of static css files
|
||||
|
||||
|
||||
# attach callback to the post search hook
|
||||
# request: flask request object
|
||||
|
@ -23,14 +26,13 @@ def post_search(request, ctx):
|
|||
|
||||
* Pre search hook (`pre_search`)
|
||||
* Post search hook (`post_search`)
|
||||
* Result hook (`on_result`) (is called if a new result is added (see https_rewrite plugin))
|
||||
|
||||
Feel free to add more hooks to the code if it is required by a plugin.
|
||||
|
||||
|
||||
### TODO
|
||||
|
||||
* Client side dependency handling
|
||||
* Better documentation
|
||||
* More hooks
|
||||
* search hook (is called while searx is requesting results (for example: things like math-solver), the different hooks are running parallel)
|
||||
* new result hook (is called if a new result is added (for example: https-rewrite))
|
||||
|
|
Loading…
Reference in New Issue