Comments (5)
may be related to #2629
not familiar w/ webpack does it use any of the javascript modules? if so you might need to switch to the new module-specific files in the distribution
from htmx.
The webpack installation documentation hasn't been updated so I assumed the setup is the same. None of the other js libraries I use in webpack need to specifiy any special module types.
https://htmx.org/docs/#webpack
from htmx.
entirely possible that those instructions are wrong now, unfortunately, since no one on the core team that I'm aware of uses webpack. We will get the .d.ts file fixed in the next release and then we can try again, and then maybe try by referencing one of the module files (/dist/htmx.esm.js
?) and then update the docs if necessary. Can you try referencing the esm file now just to see if it does anything different?
from htmx.
I figured out how to set it up correctly. I'll create a pull request to fix the documentation.
For anyone who needs it
window.htmx = require('htmx.org');
becomes
import htmx from "htmx.org/dist/htmx.esm";
window.htmx = htmx;
from htmx.
Thanks @Jesmaster you've helped me to resolve my issue.
I use Vite and I had to do a similar change there. In the vite.config.js file i had to replace htmx.org
with the htmx.org/dist/htmx.esm
:
plugins: [
inject({
htmx: 'htmx.org/dist/htmx.esm',
}),
],
This is related to: #1690
from htmx.
Related Issues (20)
- 2.0.0 umd file missing? HOT 1
- IE11 Support Remains in v2 HOT 3
- Missing CHANGELOG entry for v2.0.0
- v2.0.0 hx-target="body" hx-swap="outerHTML" produce swap error
- hx-get produces htmx:invalidPath on HTMX 2.0.0 HOT 1
- htmx:invalidPath after migration to 2.0 HOT 2
- hx-include - allow multiple extended selectors HOT 3
- Functions in Scripts Do Not Run Automatically When Script is a Module
- HTMX 2: title tag is not always updated HOT 1
- "Troublesome Tables" in documentation is unclear
- Newly Cloned Repo fails the Test command
- 2.0: TypeError: import_htmx.default.config is undefined when defining config programmatically HOT 4
- Websockets documentation link gives 404 error HOT 1
- htmx.logAll is not a function HOT 4
- `hx-disabled-elt` does not work with multiple parameterized selectors HOT 1
- more parameters included than before 2.0.0-alpha1 -> 2.0.0 HOT 7
- HTMX 2.0 with multiswap selectors after first not found HOT 2
- i got error :htmx:invalidPath for verifyPath HOT 2
- [Feature Request] Support base tag
- Confused about detail.successful and detail.failed for htmx:afterRequest HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from htmx.