st3f Posted November 27, 2019 Share Posted November 27, 2019 Hi guys, about what we where saying these days with @Rick May @GreenSock @ZachSaucier and the super-kind @OSUblake, it's really difficult to talk about the difficulties I am having with the new Draggable if some simple code working on virtual servers, production servers and online, is not working on CodePen... Unless I added some extra ";" or I copied some whatever classes And, clearly, the problem is not to intercept an onClick, but working with parametric ids in a more complex machine. Thank you for any help See the Pen QWWXxGW by st3f (@st3f) on CodePen Link to comment Share on other sites More sharing options...
OSUblake Posted November 27, 2019 Share Posted November 27, 2019 Draggable has no problem working with classes. In fact, that's usually how I make draggable stuff. The person in that other thread didn't provide an example, so I don't know what their issue was. I can say with 100% certainty that the problem is not classes. There is no onStartDrag callback. It's onDragStart. And to call a method, you need to use this. // bad changeContentText("Hey"); // not working... // good this.changeContentText("Hey"); // working... See the Pen a921cd0166788cdfbecb66c9f29c5267 by osublake (@osublake) on CodePen 4 Link to comment Share on other sites More sharing options...
st3f Posted November 27, 2019 Author Share Posted November 27, 2019 thank you very much @OSUblake. I can't copy&paste the original code so I always mistype a lot... I give up Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now