Make WordPress Core

Opened 10 years ago

Closed 10 years ago

#32196 closed defect (bug) (duplicate)

Very slow, severe latency / lag when typing certain characters in text mode

Reported by: rowd1951's profile rowd1951 Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.2
Component: Editor Keywords:
Focuses: javascript Cc:

Description

I am submitting this ticket at the suggestion of WP tech geniuses James Huff and Samuel Wood over on the WP.org forum, where this topic has been discussed at length here:

https://wordpress.org/support/topic/text-editor-extremely-slow

When typing large posts in text editor mode, if a character is introduced such as a curly quote mark “ ” ‘ ’ (but not limited to just those characters) then the text editor experiences severe (and I mean severe) lag.

It's hard to put a precise figure on how many words constitutes 'long', but it is not noticeable in shorter posts though I suspect the problem is still there, you just can't notice the lag on a smaller amount of text.

The lag is so bad that you can type and complete whole sentences blindly, before the first letter you've typed shows up on the screen.

As soon as any of the offending characters are deleted, the text editor returns to perfect functionality without any latency/lag.

The offending characters, as well as curly quotes, includes such characters as a bullet point: • or this symbol: ❏ but again, are not limited to just these, I just give them as an example.

Characters like the following work without a problem: !"£$%&*()_+{}@~'#[]

As a test, I've pasted 16,000 words of clean LipSum in a new draft post in text mode.

It works a charm, no lag whatsoever. Then, for instance, if I paste something like:

“The cat ‘sat’ on the mat”

(please note this quote uses two different types of curly quotes)

It will take ten to fifteen seconds to paste, during which time you cannot do anything.

Then when the pasted text does appear, if I want to type any more test anywhere else in the text box, I really can't, because the lag is so prohibitive.

As soon as the very last offending curly quote is removed, the text editor returns to perfect functionality.

My version of Chrome I use (as was the others over on the thread where this has been discussed) is the latest, and has no plugins installed. It is an absolutely clean install, and the computer cache has been scrubbed and bleached within an inch of its life but still the problem persists.

This problem does not present itself in any form on my computer if I use IE 11, or if the visual editor is being used.

My computer is a Toshiba Qosmio laptop, Windows 7 Home Premium, Intel i7 2.0 GHz, 64 bit with 8GB of RAM.

It makes no difference if I use the TwentyFifteen theme or any other theme, the problem is still present.

I can experience this problem on a website hosted by JustHost in USA as well as another experimental site hosted by a completely different company in Europe.

After a lot of comments back and fore, two WordPress tech guys over on that thread were able to replicate the issue on their own computers, and so have other members of the public who commented.

The only way this problem goes away is if I disable emoji using the emoji plugin. The problem then goes away entirely, so I'm surprised at the tech guys' comments over on the thread ( https://wordpress.org/support/topic/text-editor-extremely-slow?replies=25#post-6889613 ) - James Huff and Saumel Wood - both of whom could replicate it, who say they don't think it has anything to do with the emoji/Asian character support just introduced by WordPress.

Please help!

Change History (2)

#1 @kraftbj
10 years ago

  • Focuses javascript added
  • Version changed from 4.2.1 to 4.2

I recall early versions of emoji support (deployed on wordpress.com) did cause some lag by way of the TinyMCE replacement script on long posts, though improvements were made to eliminate that issue (or at least that was the goal).

#2 @Otto42
10 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #32197.

I'm going to mark this as a dupe of mine, because I tracked down why it's happening and where. It's not specific to the reported characters and circumstances, and can be seen in Firefox as well if you make your post large enough.

The characters triggering the issue only happens in Chrome, and is probably something specific to do with their JS engine. The actual issue is having the twemoji code run when you're in the text mode at all.

Note: See TracTickets for help on using tickets.