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

Init 1000 drop down list take alot of time #3101

Closed
tabaolan1987 opened this issue Sep 16, 2020 · 2 comments
Closed

Init 1000 drop down list take alot of time #3101

tabaolan1987 opened this issue Sep 16, 2020 · 2 comments

Comments

@tabaolan1987
Copy link

Summarize your issue here.

Steps to reproduce

Tell us how to reproduce this issue.

  1. Using ajax to create 1000 select html with class chosen-select

  2. Append those selects at step 1 into the table.

Expected behavior

Should not take more than 2 minutes.

Actual behavior

It took more than 2 minutes to render the chosen drop down.

Environment

  • Chosen Version: v1.8.7

  • jQuery or Prototype Version: 1.9.1

  • Browser and Version: Chrome - Version 85.0.4183.102 (Official Build) (64-bit)

  • OS and Version: WINDOW 10

Additional information

Any other information you want to share that is relevant to the issue being reported. This might include the lines of code that you have identified as causing the bug, or potential solutions and workarounds.

@pjfsilva
Copy link

Please provide a codepen or jsfiddle code example of that problem. Chosen doesn't support ajax loading of options by default so it's not clear what you are doing.

Your performance problem is most likely on the way you add/manage those options and not on chosen itself.

A very simple example with > 3900 options loads 'instant' on my machine (also very dependent on clients machine performance, of course).

@tjschuck
Copy link
Member

There is already a canonical issue for "performance issues with very large lists", but that's for lists in the 20,000+ range. Closing this as either a dupe of that (#2580), or something else happening (@pjfsilva's AJAX-loading related comments).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants