How do you plan to handle dynamically loaded HTML
See original GitHub issueUnder the Limitations section I noticed you mentioned that this library does not work for dynamically injected markup, however the library should support this at some point in the future; I was wondering if you had a plan for implementing this. It seems like using MutationObserver
is a good idea, as it is widely supported (including back to IE11), and should be able to efficiently listen to DOM mutations. I’m guessing we could observe on document.body
or something and listen for childList
mutations, determine if a child has the .lazy
class, and therefore should also be observed?
Maybe we could make mediaObserver
a variable global to this module, so we could .observe
future elements that our MO
detects. Thoughts?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:6 (4 by maintainers)
Top Results From Across the Web
Handling dynamically created HTML in JavaScript - Medium
If you have a JavaScript plugin that needs to keep state, store that state on that element's dataset. Then, in the click handler,...
Read more >Enhance Aurelia model to handle dynamically loaded HTML
Overview. Prerequisite: have some already-working aurelia app; Import the TemplatingEngine; Insert your dynamic html into the DOM (e.g. via ...
Read more >Javascript: Increasing performance using Dynamic Loading
Dynamic Script Element ... The Document Object Model (DOM) allows you to dynamically create almost any part of an HTML document using JavaScript....
Read more >Dynamically Load JavaScript - YouTube
In this video I just go over a couple of ways that you can dynamically load in JavaScript from other JavaScript code.
Read more >How to Scrape Dynamically Loaded Websites with #Selenium ...
In video #50 on my channel, I used #beautifulsoup to scrape the job listings from two sites to automate my job searching.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Oh nice, sounds fun! Excellent, we shall talk soon then.
And yeah, I’ve been contributing to Chromium + standards a bit. Ah I’m interested in seeing some of the writing if it’s been published yet!
This has been added in the 2.0.0 release. Closing.