question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Opportunity to save kb and improve performances

See original GitHub issue
  1. The framework plugins don’t need the HTML API, so we could provide a second bundle that gets rid of the global mutation observer and everything that comes with it. From my tests we could save about 5kb of script with this, plus one less mutation observer that could improve performances especially in a JS app scenario.

SimpleBar with HTML API: 949 lines SimpleBar without HTML API: 819 lines

  1. resizeObserver is now supported on most modern browser so we should probably not include the polyfill by default anymore https://caniuse.com/#feat=resizeobserver Edit: actually iOS Safari still doesn’t include it so we might keep it anyway.

  2. We should group DOM read and write (like what fastDOM is doing) to reduce layout trashing

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:2
  • Comments:12 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
Grsmtocommented, May 20, 2020

There is!

I released a new beta version: simplebar@6.0.0-beta.1. I didn’t advertise it cause I need to write changelog and everything but I’ll do a sum up here, as most suggestions in this issue were applied:

  • Remove resize-observer-polyfill entirely from the dependencies. I didn’t find an easy solution to “have it by default” and let advanced users remove it if needed, so let’s just get rid of it. I totally agree that it should be lightweight by default.
  • Move to lodash-es instead of importing the lodash/function-name version since we were very likely importing twice the same helper functions (thanks @hc-codersatlas)
  • As suggested in my initial comment, the HTML API is now separated. That saves us a few kb.
2reactions
re-thccommented, Jan 9, 2020

For saving kb why not optimize lodash too? See: https://github.com/fkhadra/react-on-screen/issues/55 for example

Read more comments on GitHub >

github_iconTop Results From Across the Web

Knowledge Base Guide: Why Your Business Needs One Today
A knowledge base improves your company's ability to create, organize, manage, and share its knowledge and exponentially put that knowledge to good use....
Read more >
The Ultimate Guide to Using a Knowledge Base for Self ...
Learn what a knowledge base is and discover how to plan, create, and deliver effective help center content to create better customer ...
Read more >
9 Simple Hacks to Write Better Knowledge Base Articles
In this article, we walk you through exactly what you need to write effective knowledge base articles that help your users learn.
Read more >
Creating and editing articles in the knowledge base
To save your new article as a draft or work in progress to publish later, click Save. Clicking Save creates the article as...
Read more >
10 Essential Tips for Improving Performance at Work
Identify your current performance issues (“what can I improve on at work”?) Analyze opportunities for performance improvement; Establish personal performance ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found