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

Prism.js laggy when highlighting big blocks of code #24

Closed
crookse opened this issue Mar 20, 2019 · 0 comments
Closed

Prism.js laggy when highlighting big blocks of code #24

crookse opened this issue Mar 20, 2019 · 0 comments
Labels
Bug Something isn't working as expected

Comments

@crookse
Copy link
Member

crookse commented Mar 20, 2019

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to /api-reference/compilers and you'll see the main thread is blocked
  2. Done.

Expected behavior
Pages with big blocks of code should not have Prism.js block the main thread. Blocking the main thread causes the page to appear frozen. You can see why this is bad.

Possible Solution(s)

  • Recompile Prism.js with minimal code/plugins.
  • Use webworker?

Screenshots
NA

@crookse crookse added the Bug Something isn't working as expected label Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
crookse added a commit that referenced this issue Mar 20, 2019
@crookse crookse closed this as completed Mar 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working as expected
Development

No branches or pull requests

1 participant