-
Notifications
You must be signed in to change notification settings - Fork 258
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"input" event should fire synchronously when input field value changes #120
"input" event should fire synchronously when input field value changes #120
Comments
I am facing the same issue. Do you have any idea how to fix this lib? |
it looks like @mvorisek , if you are up for pairing on this problem, I can help you fix it. |
@justinbmeyer thank you, I will create a repro where this issue corrupts data massively (vs. regular keyboard input) shortly. |
@justinbmeyer here is the repro: atk4/ui@8971618 steps to reproduce:
I would expect I belive the problem is that the text is mutated due race-condition between vue and syn.js as the input event generated by syn.js is not synchronous. PS: I have created #196 PR which fixes this issue and the repro. Is it all it was or do some test or anything else needs to be adjusted? |
Yeah, a test would be great. You can see them in here: https://github.com/bitovi/syn/blob/master/test/test.html |
Can you please help me with the test and create a PR againts my PR branch? I cannot run the JS tests localy nor I am sure if I can write the test properly. |
@mvorisek , yes. Would you be open to pairing with me on it? Thanks! |
Thank you, I am very happy this will be fixed as the issue is quite major. Feel free to submit more changes to #196 or just reuse the fix in your own PR. I also found some problem when using Syn.focus() which breaks Selenium and with older release the tests were passing... Investigating what events are fired by this lib and what events are fixed by regular mouse event. Also in the git I see you were working on v1 release where you fixed a lot of things incl. CI, what is the status now? What about adding GH Actions CI and integrate the changes incrementally? |
We paused development, mostly b/c we didn't know folks have been using the library much outside of Bitovi. What have you been using it for? Knowing folks are using it helps motivate us to keep maintaining it. |
This lib is used in https://github.com/minkphp/MinkSelenium2Driver/blob/master/src/Selenium2Driver.php to emulate mouse/keyboard events for Selenium testing, there are about 25k installs per day - https://packagist.org/packages/behat/mink-selenium2-driver/stats, in npm stats it is not visible, as the JS is bundled, and there are probably a lot of simillar uses. |
syn fires the "input" event asynchronously when typing into a field using
syn.type(...)
. According to the spec and MDN this event should be fired synchronously as soon as thevalue
property of the input has been updated.The text was updated successfully, but these errors were encountered: