You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.
Currently, the editor triggers an event on every keypress and this results in an multiple ajax calls and also bad user experience. (especially in the online editor)
lib.js: form.on("input", "input, textarea", function() { form.trigger("change"); });
main.js: form.on("change", function() { clearTimeout(timer); preview.addClass("loading"); timer = setTimeout(function() { var data = builder.getFormValues(); form.data("resume", data); postResume(data); }, 200); });
While there are probably many ways to optimize this, one option is to use _.debounce (lodash library is already part of lib) to rate limit the ajax requests.
I currently don't have vagrant setup but if there is enough interest I could make a pull request for this change.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Currently, the editor triggers an event on every keypress and this results in an multiple ajax calls and also bad user experience. (especially in the online editor)
lib.js:
form.on("input", "input, textarea", function() { form.trigger("change"); });
main.js:
form.on("change", function() { clearTimeout(timer); preview.addClass("loading"); timer = setTimeout(function() { var data = builder.getFormValues(); form.data("resume", data); postResume(data); }, 200); });
While there are probably many ways to optimize this, one option is to use _.debounce (lodash library is already part of lib) to rate limit the ajax requests.
I currently don't have vagrant setup but if there is enough interest I could make a pull request for this change.
The text was updated successfully, but these errors were encountered: