177 Commits

Author SHA1 Message Date
Stu Kennedy
37cf0e8c6c
WebSocket Extension (hx-ws) Improvements (#3592)
* refactor: Enhance WebSocket extension with URL normalization, improved request management, and refined message handling for better reliability and clarity.

feat: Add manual WebSocket server script and enhance WebSocket documentation with detailed message formats and connection management improvements.

feat: Include event type in WebSocket messages and update documentation for message format

* refactor: Update WebSocket extension to connect immediately by default, enhance documentation on connection triggers, and improve message handling examples.

* feat: Introduce URL validation for WebSocket send attributes to ensure proper connection handling and prevent non-URL markers from being processed.
2025-12-19 11:42:36 -07:00
Carson Gross
628b5a6a6c add update-sha.sh 2025-12-09 12:15:54 -07:00
Carson Gross
78b5e2b865 update version 2025-12-06 08:32:56 -07:00
Carson Gross
2841257abc prep release 2025-11-27 13:20:42 -07:00
Stu Kennedy
7510030e59
Websocket extension for HTMX (#3547)
* feat: add hx-ws WebSocket extension with accompanying tests and debug utilities.

* feat: Refine WebSocket extension initialization and processing logic, preventing re-initialization and ensuring comprehensive element handling.

* refactor: Enhance WebSocket connection handling with improved event triggering and dynamic configuration management

* refactor: Introduce dynamic configuration management for WebSocket connections, consolidating default settings into a dedicated function for improved maintainability and clarity.

* refactor: Update WebSocket extension to improve reconnection logic and dynamic configuration handling, enhancing maintainability and clarity.

* docs: Expand WebSocket extension documentation with detailed architecture, attributes, message formats, and example use cases for improved clarity and usability.

* refactor: Update WebSocket message structure to include default values for channel and format, enhancing clarity in documentation and implementation.

* feat: Add default `channel` and `format` values to WebSocket messages if not provided.
2025-11-23 11:38:02 -07:00
MichaelWest22
d569ce6ccf
move to registerExtension to avoid extension upgrade confusion (#3546)
* move to registerExtension to avoid extension upgrade confusion

* Also fix window.htmx export to make modules work with extensions and add initial types file

* update docs on module use

---------

Co-authored-by: MichaelWest22 <michael.west@docuvera.com>
2025-11-22 10:58:38 -07:00
Carson Gross
a7f8bebe7b prep alpha3 release 2025-11-18 10:45:30 -07:00
Carson Gross
374073e7ad docs 2025-11-10 12:25:26 -07:00
Carson Gross
5690bbc64c alpha2 prep 2025-11-10 12:14:17 -07:00
Carson Gross
0e254520af start re-implementing scroll & show, still needs focus
website now uses real preload extension!
2025-11-09 18:18:37 -07:00
Carson Gross
29d1f765a4 update build task to include extensions 2025-11-09 17:22:25 -07:00
Christian Tanul
25c2a08617
Pimp out the website for htmx 4.0 (#3499)
flatten website directory structure and redesign UI
- move all templates from themes/htmx-theme/templates/ to www/templates/
- move all static assets from themes/htmx-theme/static/ to www/static/
- remove theme layer and update config.toml
- add tailwind css with typography plugin
- update hero section with 3D effects and subtle synthwave aesthetic
- update header with improved design and navigation
- add shortcut for search bar in header (CMD+K on macos, CTRL+K elsewhere)
- add status bar in header that displays title=... attribute on hover for any element
- update footer with improved design and navigation
- rename "examples" to "patterns" throughout site and docs
- reorganize patterns page from 7 categories to 4 (loading, interaction, display, advanced)
- add mac os9 finder-style design to patterns page with Chicago FLF font (classic OS9 window title font)
- add sidebar table of contents for /docs/, /reference/, and /htmx-4/ pages (mobile version still TODO)
- add `npm run site` script that uses npx for tailwindcss and zola-bin (no external dependencies needed)
- remove github buttons.js dependency and replace with custom buttons
- consolidate sponsor images into www/static/img/sponsors/ with logo-<company>.png|svg format
- standardize all image filenames to lowercase kebab-case
- clean up unused sponsor images from www/static/img/
- create construction_warning() shortcode for work-in-progress sections
- add reusable template components (toc, anchor links, sponsors shortcode)
- add horse easter egg when URL includes ?horse=true
- update website htmx.js to latest version
- update npm dependencie
2025-11-09 10:53:39 -07:00
MichaelWest22
77c17f3717
Update build:esm to replace __ with # correclty
The build system for esm is not replacing __ with # for some async prefixed functions causing the esm version to not run correctly
2025-11-06 16:10:41 +13:00
Carson Gross
cac0f1387f fix package 2025-11-03 11:46:20 -07:00
Carson Gross
72d6b7888f fix URL 2025-11-03 11:43:54 -07:00
Carson Gross
e3578992e9 kick netlify 2025-11-03 11:33:06 -07:00
Carson Gross
2d0839a928 move code into four branch 2025-10-26 13:26:44 -06:00
Carson Gross
49d6aa3752 prep 2.0.8 release 2025-10-24 20:42:29 -06:00
MichaelWest22
56299971ce
Update Node Versions and types to fix latest tsc upgrade issues (#3455)
* Update Node Versions and types to fix latest tsc upgrade issues

* fix playwright only test filtering that has broken from playwright browser updates

---------

Co-authored-by: MichaelWest22 <michael.west@docuvera.com>
2025-10-14 05:19:20 -06:00
Carson Gross
449c8e9531 prep next release 2025-09-07 12:13:49 -06:00
Carson Gross
fe7f103eab prep 2.0.6 release 2025-06-27 07:39:35 -06:00
Carson Gross
683c0e8ae2 prep 2.0.5 release 2025-06-20 15:29:01 -06:00
Simon Hartley
3c1ac71573
Follow up to #3234 (#3334)
* Follow up to #3234

Add missing part of migration from UNPKG to jsDelivr

* Restore UNPKG support in package.json

---------

Co-authored-by: scrhartley <scrhartley@github.com>
2025-06-16 16:37:26 -06:00
Carson Gross
0aaab5a3c9 Merge branch 'master' into dev
# Conflicts:
#	package-lock.json
#	package.json
2025-06-02 11:52:35 -06:00
Piotr Tomiak
11ff1940f0
Automatically generate Web Types for the package based on current documentation (#3071) 2025-06-02 11:25:23 -06:00
Vincent
53c5cf6df7
Remove obsolete npm command + fix links to ws/sse extensions (#3208)
Remove obsolete npm command + fix links to ws/SSE
2025-06-02 11:21:11 -06:00
MichaelWest22
083dbcdd6f
update web test-runner and remove temp summaryReporter workaournd (#3320)
* update web test-runner and remove temp summaryReporter workaournd

* Update error reporting to show in context of the test file and as a summary at the bottom
2025-05-22 07:17:16 +02:00
Simon Hartley
ff190eef26
Add substr lint (#3295)
Co-authored-by: scrhartley <scrhartley@github.com>
2025-04-28 07:15:03 +02:00
MichaelWest22
24a0106f76
Update testing framework to web-test-runner and improve code coverage (#3273)
* Fix old npm dependencies

* implement web-test-runner tests for headless alongside Mocha browser tests

* Increase test and code coverage

* update to 100% coverage and impove eslint

* Update testing Doco

* revert all htmx changes and updates/disable tests needed

* fix browser mocha test

* Default testing to use playwrite only instead of puppeter

* playwright install fix

* Imporve test summary reporting

* flatten false looks closer to original
2025-04-17 17:55:43 -06:00
Carson Gross
fb78106dc6 prep next release 2024-12-12 13:12:49 -07:00
Carson Gross
d9b4ada06b release prep 2024-10-02 20:19:43 -06:00
MichaelWest22
2ba7fd280e
Upgrade Typescript to move configuration from const to let (#2853)
* typescript upgrade v5.5.4

* fix dist
2024-08-29 10:30:51 -06:00
Carson Gross
97b8c68dd3 release prep 2024-08-05 13:53:08 -06:00
Alexandre Spaeth
a30e96b553
Fix package.json configuration for types (#2769)
* Generate .d.ts file from the esm module (#2733)

* Fix types annotation filename in package.json (#2734)

---------

Co-authored-by: Alexandre Spaeth <alex_erson@users.noreply.github.com>
2024-07-29 17:54:06 -04:00
Alexandre Spaeth
6a800e8085
Generate .d.ts file from the esm module (#2733) (#2734)
Co-authored-by: Alexandre Spaeth <alex_erson@users.noreply.github.com>
2024-07-26 00:26:59 -04:00
Carson Gross
2f38ac7c55 add sha as an npm command and update for release 2024-07-12 11:16:04 -06:00
Carson Gross
52b357089d bump version and make the esm version "main" 2024-06-27 13:40:02 -06:00
Alexander Petros
e1143de850
Generate .d.ts file in build script (#2653)
* Generate .d.ts file in build script

Resolves: #2629

* Streamline configuration options

Delete the JSConfig so we don't have to un-specify options when checking
vs generating (and also to remove a config file). Steamline the options
by re-using the NPM commands.

* Remove type generating from dev script
2024-06-20 11:18:47 -06:00
Carson Gross
505a093ba7 2.0 release 2024-05-23 13:15:37 -06:00
Carson Gross
d7d1519be9 bump version 2024-05-22 15:05:06 -06:00
Carson Gross
74744ac337 prep for 2.0.0-beta3 release 2024-04-17 11:04:49 -06:00
Carson Gross
bf69273701 beta2 2024-03-21 16:02:23 -06:00
Carson Gross
e3330db4a3 prep beta1 2024-03-13 16:00:27 -06:00
Vincent
9a1cbfd2e9 Run types check in npm t (#2336 follow-up) 2024-03-03 16:06:32 +01:00
Vincent
f004978bbb
JSdoc in htmx.js + generated TypeScript definition (#2336)
* JSdoc in htmx.js + generated TypeScript definition

* Tsc trick to avoid inlining functions and reduce diff

* Replace Queryable with ParentNode

* Simplify getRawAttribute type check
2024-02-21 15:34:59 -06:00
Carson Gross
c16758a198 alpha2 2024-02-09 11:13:47 -07:00
Carson Gross
fd775f84be fix version and lint 2024-01-23 12:53:58 -07:00
Carson Gross
0a2c375970 Merge remote-tracking branch 'origin/v2.0v2.0' into v2.0v2.0 2024-01-23 12:16:08 -07:00
Vincent
b9322450ff
Migrate to FormData (#2226)
* use form data instead of plain objects [wip]

* FomData fixes + some JSDoc. TODO prevent multiple inclusions

* Linted code

* Prevent double value inclusions

---------

Co-authored-by: Deniz Akşimşek <deniz@denizaksimsek.com>
2024-01-23 12:15:18 -07:00
Alexander Petros
4af2f75ae1 Run linter with 'npm run test' 2024-01-18 10:22:15 -05:00