Skip to content

add migration rule to change preload to hx-preload in upgrade checker - #3994

Merged
1cg merged 1 commit into
bigskysoftware:four-devfrom
AshwinSundar:as-upgrade-checker-preload
Aug 30, 2026
Merged

add migration rule to change preload to hx-preload in upgrade checker#3994
1cg merged 1 commit into
bigskysoftware:four-devfrom
AshwinSundar:as-upgrade-checker-preload

Conversation

@AshwinSundar

@AshwinSundar AshwinSundar commented Aug 30, 2026

Copy link
Copy Markdown

Description

Please describe what changes you made, and why you feel they are necessary. Make sure to include
code examples, where applicable.

Htmx 2 docs recommend calling the extension with the preload attribute ( https://htmx.org/extensions/preload/),, "‌") while in htmx 4 you need to call the attribute hx-preload. This PR adds a migration rule to the Upgrade Checker to warn the user of this change.

Corresponding issue:

Testing

Please explain how you tested this change manually, and, if applicable, what new tests you added. If
you're making a change to just the website, you can omit this section.

I had this issue in a codebase which uses HTMX, and ran ./upgrade-check.js against my repo to make sure it found any usage of preload instead of hx-preload.

I ran npm test locally to make sure all 87 test files passed.

Checklist

  • I have read the contribution guidelines
  • I have targeted this PR against the correct branch (master for website changes, dev for
    source changes)
  • This is either a bugfix, a documentation update, or a new feature that has been explicitly
    approved via an issue
  • I ran the test suite locally (npm run test) and verified that it succeeded

@1cg
1cg merged commit 918646b into bigskysoftware:four-dev Aug 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants