aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorYarden Shoham <git@yardenshoham.com>2024-02-01 00:36:23 +0200
committerGitHub <noreply@github.com>2024-01-31 23:36:23 +0100
commit4989ad0a9f097fdd8d642aa10f4c203f861debea (patch)
tree8c8f32d22a0249ec21427fd33d922c0970736f5d /docs
parent3b50dd95cefc003d72b5ef5b77c28e8a4d30795c (diff)
downloadgitea-4989ad0a9f097fdd8d642aa10f4c203f861debea.tar.gz
gitea-4989ad0a9f097fdd8d642aa10f4c203f861debea.zip
Add htmx guidelines (#28993)
To make sure we don't abuse it. --------- Signed-off-by: Yarden Shoham <git@yardenshoham.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: delvh <dev.lh@web.de>
Diffstat (limited to 'docs')
-rw-r--r--docs/content/contributing/guidelines-frontend.en-us.md3
1 files changed, 3 insertions, 0 deletions
diff --git a/docs/content/contributing/guidelines-frontend.en-us.md b/docs/content/contributing/guidelines-frontend.en-us.md
index aa1759d9c9..edd89e1231 100644
--- a/docs/content/contributing/guidelines-frontend.en-us.md
+++ b/docs/content/contributing/guidelines-frontend.en-us.md
@@ -65,14 +65,17 @@ Recommended implementations:
* Vue + Vanilla JS
* Fomantic-UI (jQuery)
+* htmx (partial page reloads for otherwise static components)
* Vanilla JS
Discouraged implementations:
* Vue + Fomantic-UI (jQuery)
* jQuery + Vanilla JS
+* htmx + any other framework which requires heavy JS code, or unnecessary features like htmx scripting (`hx-on`)
To make UI consistent, Vue components can use Fomantic-UI CSS classes.
+We use htmx for simple interactions. You can see an example for simple interactions where htmx should be used in this [PR](https://github.com/go-gitea/gitea/pull/28908). Do not use htmx if you require more advanced reactivity, use another framework (Vue/Vanilla JS).
Although mixing different frameworks is discouraged,
it should also work if the mixing is necessary and the code is well-designed and maintainable.