red-farmer-97020
03/07/2022, 7:30 PMmysterious-toddler-20573
03/07/2022, 7:30 PMmysterious-toddler-20573
03/07/2022, 7:31 PMready stuff. That would be cleaner.mysterious-toddler-20573
03/07/2022, 7:31 PMmysterious-toddler-20573
03/07/2022, 7:31 PMwhite-motorcycle-95262
03/07/2022, 7:35 PMhtmx.onLoad() js call, so I thought maybe re-initializing the dropdowns would work, not sure yet tho
EDIT: This doesn't seem to work, which is strange to mewhite-motorcycle-95262
03/07/2022, 8:05 PMhx-push-url to False, will History support be disabled? Is it possible to set hx-boost="true" and hx-push-url="false" together?mysterious-toddler-20573
03/07/2022, 8:23 PMmysterious-toddler-20573
03/07/2022, 8:23 PMwhite-motorcycle-95262
03/07/2022, 8:30 PMmysterious-toddler-20573
03/07/2022, 8:44 PMmysterious-toddler-20573
03/07/2022, 8:44 PMmysterious-toddler-20573
03/07/2022, 8:44 PMwhite-motorcycle-95262
03/07/2022, 8:48 PMwhite-motorcycle-95262
03/07/2022, 8:50 PM'{"historyEnabled": false}' in a meta tag broke all sorts of things, so I suppose having that enabled but setting historyCacheSize should have been a winning solutionmysterious-toddler-20573
03/07/2022, 8:52 PMwhite-motorcycle-95262
03/07/2022, 8:58 PMmysterious-toddler-20573
03/07/2022, 8:59 PMwhite-motorcycle-95262
03/07/2022, 9:01 PMwhite-motorcycle-95262
03/08/2022, 1:57 PMevent in debug console and they work fine when using browser "back."
However, the dropdowns, even when they do work properly (i.e., in normal browsing and not pressing "back") do not show an associated event in browser tools, so I suppose Bootstrap has some other method for determining clicks (I just noticed that there are a lot of event listeners on the <html> tag that come from bootstrap/js/src/dom/event_listener.js).white-motorcycle-95262
03/08/2022, 4:49 PM<body>. So "going back" apparently made them load multiple times, or at least repeat event listeners (I noticed hyperscript was also doubling behaviors), so it wasn't that Dropdowns weren't working, but that they were getting fired twice.
I suppose loading JS libs in the head is the solution, but I always heard it was best to load them last. I don't think it's a huge deal to load them in the header, but just wondered what your thoughts were.
EDIT: So, I went ahead and removed the historyCacheSize: 0 config and things still work as they shouldgreen-flower-49070
03/08/2022, 4:51 PMgreen-flower-49070
03/08/2022, 4:52 PMgorgeous-ghost-95789
03/08/2022, 4:53 PMgorgeous-ghost-95789
03/08/2022, 4:53 PMgorgeous-ghost-95789
03/08/2022, 4:53 PMhtmx.process() on the new nodes so they htmx knows about them.gorgeous-ghost-95789
03/08/2022, 4:54 PMgreen-flower-49070
03/08/2022, 4:54 PMgreen-flower-49070
03/08/2022, 5:16 PMgorgeous-ghost-95789
03/08/2022, 5:18 PM