kode-team / codemirror-colorpicker

colorpicker with codemirror
https://colorpicker.easylogic.studio/
MIT License
137 stars 13 forks source link

Too slow when paste a long text #14

Closed sylingd closed 7 years ago

sylingd commented 7 years ago

For example, there are tow pages, 1.html has colorpicker plugin and 2.html not 1.html 2.html

If paste a long text (more than 30000, for example, this file ), the 1.html will be "no response" in about 10 seconds. I use "Performance" tool in Chrome's devtools, it shows that most of the time is spent on "Layout" 2017-11-20_235849

If in a complex web page, the situation is more serious.

Here is Google's document

You can load my performance profile 2017-11-21_000050

(I did not delve into it, but maybe asynchronous initialization can solve the problem?)

easylogic commented 7 years ago

hi @sylingd

Thanks for your report.

I will check it .

easylogic commented 7 years ago

i fixed this issue.

please test it in v1.0.10

sylingd commented 7 years ago

It works well, thank you