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

Performance improvements #43

Open
wants to merge 69 commits into
base: master
Choose a base branch
from
Open

Conversation

HenryMarshall
Copy link

I've been working on adding some performance improvements to GhostScroll over the last few days and thought some or all of them might be appreciated upstream. This PR functions almost identically to the base version, but has a few changes:

  • Graceful degredation for navigation box through deep-linking
  • Styling done purely with CSS, no classes added by JS at runtime
  • Improved JS perfomance
  • Build step added to permit concatenation and minification of files (PageSpeed Insights score of 100)
  • Buttons on hero are handlebars {{navigation}} so the user does not need to ever modify the theme directly.

If some subset of these changes (for example: not the build step) would be of interest, please let me know and I'd be happy to oblige.

The existing strategy caused each matching font-awesome substitution to
cause two separate DOM calls (one to read, one to write). The new
strategy uses regex and makes only a single replacement for the whole
document.
Using @import has performance penalties as normalize cannot be requested
until screen has already been loaded.
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

Successfully merging this pull request may close these issues.

1 participant