Comments (2)
This could be heavy on performance but I guess still good to have if anyone wants to use it. I imagine something similar to jQuery's :contains selector:
document.arrive('.elem:contains(Hello)', (e) => {
console.log(e);
});
Note: We don't use jQuery in the library so :contains have to be custom implemented.
from arrive.
.elem:contains(Hello)
Pretty sure this was exactly the use case I was referring to at the time. I've since quit using jQuery, in favor of writing my own terrible js.
Custom :contains
would work, but might be confusing, given that it's heavily associated with jQuery. Either way, the goal would be to enable something like fireOnCharacterDataModification
.
This isn't something I've experimented with since the OP while using arrive, so if it's already capable of firing on text change, it's a non-issue. If not, it would be a solid feature. =)
from arrive.
Related Issues (20)
- Can we use this in Angular 4? HOT 1
- Feature request: respond to arrival of multiple elements HOT 3
- Possible Human Error | HOT 1
- Can we get typescript types? HOT 1
- Watch for multiple classes HOT 2
- Option to let fire multiple times for a single element HOT 2
- Can't get it to work in pure JS HOT 22
- Error in readme.md HOT 1
- Remove dependency on jquery-2.1.0.min.js HOT 1
- HTMLElement.matches in old Opera
- Cannot read property '0' of undefined HOT 1
- Fire only once, total HOT 3
- Promise and Async/Await Support HOT 4
- Feature suggestion: Add timeout
- How to import from npm? HOT 3
- Detect page title change HOT 5
- delete please, created by mistake
- why it rescan elements exponentially? HOT 1
- jQuery selectors are not supported
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 arrive.