WPIntell

Source evidence

Unused JS impacting site performance

Social Sharing Plugin – Sassy Social Share · support · 2025-06-20T14:14:00+00:00

complaintsentiment
highseverity
1.0relevance
5replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

7 / 29 rows with source links

24.1% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

22 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
savingyourtail unresolved
Hi, I’ve been working on improving my site’s pagespeed insights score and a warning/issue I’ve gotten is that my site has some unused javascript from the plugin. Below is the file being flagged. At 42KB it’s a sizeable amount of content being sent and impacting performance that is unnecessary if true. Is it possible to remove this unused JS? Here’s a page about it from google: https://developer.chrome.com/docs/lighthouse/performance/unused-javascript/?utm_source=lighthouse&utm_medium=lr …js/sassy-social-share-public.js?ver=3.3.76 41.7 KiB The page I need help with: [ log in to see the link] Hi, Sure. For now, you can add the following code in the functions.php file of your active theme to unload the Javascript file. /** * Initialization */ function heateor_sss_custom_init() { add_action( 'wp_enqueue_scripts', 'heateor_dequeue_js_css' ); } add_action( 'init', 'heateor_sss_custom_init' ); /** * Dequeue the Javascript file of Sassy Social Share */ function heateor_dequeue_js_css() { wp_dequeue_script( 'heateor_sss_sharing_js' ); } Hi, I tried this code, but it appears to have broken some of the sassy share features, for example the copy link button and the “more” share options button, so I had to remove it. (Though strangely, other share icons still worked). I guess this means there are some code elements within sassy-social-share-public.js that are -not- unused? Is it possible to strip out only these unused javascript within the .js file? Yes, these share buttons depend on the JS file. It’s not possible to strip the unused code from the JS file. You should be ignoring this warning then. Is it possible for the developer to modify the plugin in a way that deactivates unused code in a future update? This is the only plugin on my site, and I have many, that has unused code showing up in pagespeed insights without a way to disable those elements. And I have some really big plugins that I’m only using a few features of, so I think this is a common practice in other plugins that helps ensure optimal site performance. Thanks We will take care of it in the upcoming updates.

Comments

5 shown
Rajat Varlani 2025-06-21T02:26:00+00:00

Hi, Sure. For now, you can add the following code in the functions.php file of your active theme to unload the Javascript file. /** * Initialization */ function heateor_sss_custom_init() { add_action( 'wp_enqueue_scripts', 'heateor_dequeue_js_css' ); } add_action( 'init', 'heateor_sss_custom_init' ); /** * Dequeue the Javascript file of Sassy Social Share */ function heateor_dequeue_js_css() { wp_dequeue_script( 'heateor_sss_sharing_js' ); }

savingyourtail 2025-06-21T03:17:00+00:00

Hi, I tried this code, but it appears to have broken some of the sassy share features, for example the copy link button and the “more” share options button, so I had to remove it. (Though strangely, other share icons still worked). I guess this means there are some code elements within sassy-social-share-public.js that are -not- unused? Is it possible to strip out only these unused javascript within the .js file?

Rajat Varlani 2025-06-21T14:25:00+00:00

Yes, these share buttons depend on the JS file. It’s not possible to strip the unused code from the JS file. You should be ignoring this warning then.

savingyourtail 2025-06-21T15:01:00+00:00

Is it possible for the developer to modify the plugin in a way that deactivates unused code in a future update? This is the only plugin on my site, and I have many, that has unused code showing up in pagespeed insights without a way to disable those elements. And I have some really big plugins that I’m only using a few features of, so I think this is a common practice in other plugins that helps ensure optimal site performance. Thanks

Rajat Varlani 2025-07-09T11:49:00+00:00

We will take care of it in the upcoming updates.