Skip to content

Commit 47bdec5

Browse files
committed
Merge branch 'gohugo' into dev
# Conflicts: # www/attributes/hx-target.md # www/content/docs.md # www/content/events.md # www/content/examples/animations.md # www/reference.md # www/static/test/index.html
2 parents 2fe7545 + b0088a6 commit 47bdec5

File tree

4,337 files changed

+2567
-2829
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,337 files changed

+2567
-2829
lines changed

netlify.toml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[build]
2+
base = "www"
3+
publish = "public"
4+
command = "zola build"
5+
6+
[build.environment]
7+
ZOLA_VERSION = "0.17.1"
8+
9+
[context.deploy-preview]
10+
command = "zola build --base-url $DEPLOY_PRIME_URL"

scripts/www.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ var fs = require('fs-extra');
33

44
console.log(config.version)
55

6-
var testRoot = "www/test/";
6+
var testRoot = "www/static/test/";
77
var currentReleaseRoot = testRoot + config.version;
88
fs.ensureDirSync(currentReleaseRoot);
99
fs.copySync("node_modules/mocha/mocha.js", currentReleaseRoot + "/node_modules/mocha/mocha.js");

www/.eleventy.js

Lines changed: 0 additions & 10 deletions
This file was deleted.

www/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
public/**

www/README.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
## Running The Website Locally
22

3-
The htmx.org website is built on [eleventy](https://www.11ty.dev/).
4-
To run the site, use node 15 and run:
3+
The htmx.org website is built with [Zola](https://www.getzola.org/).
4+
To run the site, [install Zola](https://www.getzola.org/documentation/getting-started/installation/); then, from the root of the repository:
55

66
```
7-
npm install
8-
npx eleventy --serve
7+
cd www
8+
zola serve
99
```
1010

11-
The site should then be available at <http://localhost:8080>
12-
13-
**macOS 64-bit users may need to run `npm rebuild node-sass` to get the documentation site working.**
11+
The site should then be available at <http://localhost:1111>

www/_includes/demo_layout.njk

Lines changed: 0 additions & 8 deletions
This file was deleted.

www/_includes/demo_ui.html.liquid

Lines changed: 0 additions & 59 deletions
This file was deleted.

www/attributes/hx-target.md

Lines changed: 0 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +0,0 @@
1-
---
2-
layout: layout.njk
3-
title: </> htmx - hx-target
4-
---
5-
6-
## `hx-target`
7-
8-
The `hx-target` attribute allows you to target a different element for swapping than the one issuing the AJAX
9-
request. The value of this attribute can be:
10-
11-
* a CSS query selector of the element to target
12-
* `this` which indicates that the element that the `hx-target` attribute is on is the target
13-
* `closest <CSS selector>` which will find the closest parent ancestor that matches the given CSS selector.
14-
(e.g. `closest tr` will target the closest table row to the element)
15-
* `next <CSS selector>` which will find the next element in the DOM from the element that the `hx-target` attribute is on matching the given CSS selector.
16-
* `previous <CSS selector>` which will find the previous element in the DOM from the element that the `hx-target` attribute is on matching the given CSS selector.
17-
* `find <CSS selector>` which will find the first child descendant element that matches the given CSS selector.
18-
(e.g `find tr` will target the first child descendant row to the element)
19-
20-
Note that in all cases, the CSS selector may be wrapped in a `<` and `/>`, mimicking the [query literal](https://hyperscript.org/expressions/query-reference/) syntax of
21-
hyperscript.
22-
23-
Here is an example that targets a div:
24-
25-
```html
26-
<div>
27-
<div id="response-div"></div>
28-
<button hx-post="/register" hx-target="#response-div" hx-swap="beforeend">
29-
Register!
30-
</button>
31-
</div>
32-
```
33-
34-
The response from the `/register` url will be appended to the `div` with the id `response-div`.
35-
36-
This example uses `hx-target="this"` to make a link that updates itself when clicked:
37-
```html
38-
<a hx-post="/new-link" hx-target="this" hx-swap="outerHTML">New link</a>
39-
```
40-
41-
### Notes
42-
43-
* `hx-target` is inherited and can be placed on a parent element

www/attributes/hx-validate.md

Lines changed: 0 additions & 15 deletions
This file was deleted.

www/config.toml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
base_url = "https://htmx.org"
2+
title = "</> htmx - high power tools for html"
3+
theme = "htmx-theme"
4+
5+
compile_sass = false
6+
build_search_index = false
7+
generate_feed = true
8+
9+
taxonomies = [
10+
{ name = "tag", render = false, feed = true }
11+
]
12+
13+
[markdown]
14+
highlight_code = true
15+
highlight_theme = "two-dark"
16+
external_links_target_blank = true
17+
smart_punctuation = true
18+
19+
[slugify]
20+
paths_keep_dates = true
21+
22+
[extra]
23+
# Put all your custom variables here
24+
25+
## Candidate code highlighting schemes:
26+
# 1337
27+
# ayu-mirage
28+
# boron
29+
# charcoal
30+
# material-dark
31+
# monokai
32+
33+
# subway-madrid
34+
# subway-moscow
35+
# Tomorrow
36+
# two-dark
37+
# visual-studio-dark
38+
# zenburn

0 commit comments

Comments
 (0)