Giter Club home page Giter Club logo

Comments (11)

youradds avatar youradds commented on June 24, 2024 1

@voidgraphics I ended up using inview, but when I added dynamic content I then just did this to refresh the DOM elements:

window.inView('.photo').check();

Works well for me :)

from in-view.

Jetski5822 avatar Jetski5822 commented on June 24, 2024 1

Go with Scrollama... it’s uses IntersectionObserver.

Works perfectly

from in-view.

youradds avatar youradds commented on June 24, 2024

It would appear not :/ Looks like I'm going to have to look for another module now, as I've just found out this one doesn't support dynamically added content. Eugh

from in-view.

voidgraphics avatar voidgraphics commented on June 24, 2024

@youradds have you found one? πŸ˜„

from in-view.

DanielRuf avatar DanielRuf commented on June 24, 2024

@youradds @voidgraphics see https://github.com/DanielRuf/noopener/blob/master/src/index.js and especially https://davidwalsh.name/detect-node-insertion

from in-view.

voidgraphics avatar voidgraphics commented on June 24, 2024

@DanielRuf interesting (and clever) solution by Mr. Walsh, however that does not feel very clean to me. I'd rather use a MutationObserver, which is the solution I am pursuing right now, but I was wondering if there was another in-view library that had this functionality baked-in.

Thank you for your answer πŸ™‚

from in-view.

DanielRuf avatar DanielRuf commented on June 24, 2024

MutationObserver

https://caniuse.com/#feat=mutationobserver

from in-view.

Jetski5822 avatar Jetski5822 commented on June 24, 2024

@voidgraphics what did you come up with for mutationobserver?

from in-view.

voidgraphics avatar voidgraphics commented on June 24, 2024

I ended up still using this library and adding another MO on top, but that felt really hacky and dirty so I wouldn't recommend going that route.

I think @youradds's suggestion might be better.

from in-view.

Jetski5822 avatar Jetski5822 commented on June 24, 2024

I found this one.. https://github.com/russellgoldenberg/scrollama - trying to cut my ties with jQuery and move to be more native. It uses IntrospectionObserver which should be lighter on the site.

from in-view.

oelbaga avatar oelbaga commented on June 24, 2024

ScrollMagic is probably the next best bet, and it just started to be maintained again after a donation.

from in-view.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.