Skip to content
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

Sample handles quick changes to large content badly #1132

Closed
jaredwindover opened this issue Mar 21, 2015 · 4 comments
Closed

Sample handles quick changes to large content badly #1132

jaredwindover opened this issue Mar 21, 2015 · 4 comments
Labels
Expected Behavior This is how MathJax works Feature Request

Comments

@jaredwindover
Copy link
Contributor

sample-dynamic-2.html ignores changes to the content if its currently rendering the mathjax. I largely copy-pasted the code into my own tool and found this to be a bit of an annoyance, resulting in me adding spaces to see changes, or typing and deleting quickly. Also doesn't really make sense since there's a queue being used.

@pkra pkra added the Expected Behavior This is how MathJax works label Mar 23, 2015
@pkra
Copy link
Contributor

pkra commented Mar 23, 2015

Thanks for the comment. The motivation for not rendering while typesetting is performance. Queuing every change while typing can lead to large queues of edits that the author does not actually need, reducing performance. Arguably, this was more the case when this sample was written in 2012. I suppose when #933 is solved, this sample could clean the queue and then queue the new content. But when this sample was written, this was the best compromise.

For now, I've marked this expected behavior since the sample was intentionally written this way. Happy to discuss this further but fwiw, it sounds to me like your local change is pretty much on target: the samples are meant as a base to be modified for other use cases.

@jaredwindover
Copy link
Contributor Author

I see what you mean about queuing every change. What about just setting a flag that the content has changed while typesetting and we should call CreatePreview again afterwards? I know the samples aren't intended to be complete tools, but it seems to me there must be a better option than dropping any changes while typesetting.

@pkra
Copy link
Contributor

pkra commented Mar 24, 2015

Good point. For lack of a better term, I'm tagging this feature request. PR is welcome.

@pkra
Copy link
Contributor

pkra commented Apr 2, 2015

Fixed by #1148 -- thanks again for the contribution!

@pkra pkra closed this as completed Apr 2, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Expected Behavior This is how MathJax works Feature Request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants