Git Product home page Git Product logo

Comments (8)

FRSgit avatar FRSgit commented on May 30, 2024

Hey @dashukin,

Actually resolution of #19 was intended to fix any compatibility issues with third-party libraries (I had mainly jQuery in mind).
Can you show us any example in which you get an error/some unexpected behaviour?

Nevertheless I think that adding pointer to original function may be helpful in some uncommon situations, so why not?
I could put it under an _original attribute of function created in prepareSafeListener, so it would be accessible under .addEventListener._original.
@zzarcon what do you think?

from default-passive-events.

dashukin avatar dashukin commented on May 30, 2024

Hey, @FRSgit
thank you for quick reply! Unfortunatelly I still canot reproduce the issue I'm facing with in a separate sandbox, but will try to dive into the details more deeply. In general I can see that chrome mobile emulator fires some handlers with click events, with preventDefault method set to noop function, while on real devices everything works fine... I will let you know when any new details are received so we could analyze if this a setup issue or something that could be handled from your library.

from default-passive-events.

FRSgit avatar FRSgit commented on May 30, 2024

Okay, so if you can try to come up with some reproducing-scenario it would be perfect for me.
But if it won't be so simple then please give me more info about you environment & codebase you use when getting this errors.

As I understand that problem can be connected with sandbox in which you run your app, but I cannot be 100% sure until I see your configuration.
We are in the same timezone (or almost-same) I guess, so you can always try to show me your problem via some screensharing app (like hangouts or sth).

from default-passive-events.

FRSgit avatar FRSgit commented on May 30, 2024

Since we needed to revert back fix that was made for #19 (details in #23) this issue is gone in 1.0.8.

@dashukin can you please check on your end if everything's okay?

from default-passive-events.

samal-rasmussen avatar samal-rasmussen commented on May 30, 2024

Hi @FRSgit. The element.addEventListener._original function just worked fine for me as a workaround for the issue with d3-drag that I had here: d3/d3-drag#51

Just FYI, so you know it was actually useful for someone :)

from default-passive-events.

samal-rasmussen avatar samal-rasmussen commented on May 30, 2024

Also, there was no interest in fixing the issue in d3 upstream: d3/d3-drag#52

from default-passive-events.

FRSgit avatar FRSgit commented on May 30, 2024

Well, I completely understand that they doesn't want any non-standard functionalities in their code.
For now, the only thing you can (and should) do when using default-passive-events library is to bring back _original listener before initializing d3-drag.

Of course we could support some parameter which you would put on a element to flag that it should be ignored by our library, but I'm not sure if that's not an overkill. We want to keep library as simple & fast as possible.

from default-passive-events.

FRSgit avatar FRSgit commented on May 30, 2024

Okay, closing this now as _original function was implemented correctly and is already included in README page. Hopefully more of you will be happy to use it 😃

from default-passive-events.

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.