searxng/docs
Martin Fischer 3f77ff29a3 [fix] plugin JS/CSS dependencies depend on themes
SearXNG supports plugins. Plugins can declare JavaScript and CSS
dependencies. Currently three plugins declare such dependencies:

* search_on_category_select (on by default)
* vim_hotkeys
* infinite_scroll

If a user enables a plugin its JavaScript and CSS dependencies are
embedded into every page. Sounds simple right?

Ironically in the Simple theme things start to get complicated:
The scripts were originally written for the Oscar theme and thus depend
on jQuery (which isn't loaded in the Simple theme) and look for certain
element identifiers (which aren't present in the Simple theme).  So how
did the plugins actually work with the simple theme?

The simple theme just didn't embed the plugin dependencies (which wasn't
even documented anywhere). Instead the simple theme checked if the paths
contained a certain script path, then set an attribute, which 00_init.js
detected and turned into a boolean, which was then used to enable
vanilla-JS reimplementations of the plugins.

This commit ends this horrible hack (and fixes #769).  The necessary
changes to the Simple theme are introduced in the next commit.
2022-01-18 19:03:15 +01:00
..
_themes/searxng [doc] highlight the current page in the sidebar 2022-01-10 10:48:13 +01:00
admin [docs] Switch from searx to SearXNG 2022-01-17 10:05:13 +01:00
build-templates [doc] filtron.sh - install github.com/searxng/filtron 2021-11-21 17:13:34 +01:00
dev [fix] plugin JS/CSS dependencies depend on themes 2022-01-18 19:03:15 +01:00
src [enh] add redis connector searx/shared/redisdb.py 2022-01-03 20:56:39 +01:00
user [doc] move Multilingual Search from user to admin docs 2022-01-10 10:38:15 +01:00
utils [doc] filtron.sh - install github.com/searxng/filtron 2021-11-21 17:13:34 +01:00
conf.py [fix] Documentation of the builtin plugins 2022-01-07 19:59:42 +01:00
index.rst [docs] move searxng_extra/ stuff to the developer section. 2022-01-03 10:20:54 +01:00