ahmedkaludi / core-web-vitals-pagespeed-booster Goto Github PK
View Code? Open in Web Editor NEWPageSpeed Enhancer for Web Vitals
PageSpeed Enhancer for Web Vitals
=== Core Web Vitals & PageSpeed Booster === Contributors: magazine3 Requires at least: 3.0 Tested up to: 6.5 Stable tag: 1.0.19 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Tags: core web vitals, optimization, pagespeed, performance, cache == Description == <h4>Core Web Vitals (CWV) is the new ranking factor</h4> Google announced that "Core Web Vitals" are going to be a significant ranking signal for websites. In fact, Core Web Vitals or the page experience signal is going to become a requirement for a page to appear in Google's Top Stories. ### Features * <strong>Flush Cache</strong>: Using this option you can choose on which events ( Wordpress Update,Switching Theme,Post/Page Deletion ) you want to clear website cache. * <strong>Auto Clear Cache</strong>: Clear you website on regular intervals , this helps you to keep your website cache updated. * <strong>Webp images</strong>: If images are slowing down your website, then converting them to WebP format can improve your page load speed test scores. * <strong>Lazy Load</strong>: Lazy loading allows your website to only load images when a user scrolls down to a specific image, which reduces website load time and improves website performance. * <strong>Minification</strong>: If you are trying to achieve 100/100 score on Google Pagespeed or GTMetrix tool, then minifying CSS and JavaScript will significantly improve your score. * <strong>Remove Unused CSS</strong>:Unused CSS is any CSS code added by your WordPress theme or plugins that you don’t really need. Removing this CSS code improves WordPress performance and user experience. * <strong>Google Fonts Optimizations</strong>: You may start noticing external resources like fonts affecting Google PageSpeed + load times. This is where loading Google Fonts locally comes into play. * <strong>Delay JavaScript Execution</strong>:You can delay JavaScript based on user interaction. This can be a great way to speed up the paint of the page for Google PageSpeed when something isn't needed right away. Especially heavy third-party scripts like Google Adsense, Google Analytics etc. * <strong>Cache</strong>: Caching is one of the most important and easiest ways to speed up WordPress! it reduces the amount of work required to generate a page view. As a result, your web pages load much faster, directly from cache. ### Support We try our best to provide support on WordPress.org forums. However, We have a special [team support](https://webvitalsdev.com/#text-3) where you can ask us questions and get help. Delivering a good user experience means a lot to us and so we try our best to reply each and every question that gets asked. ### Bug Reports Bug reports for Core Web Vitals & PageSpeed Booster are [welcomed on GitHub](https://github.com/ahmedkaludi/core-web-vitals-pagespeed-booster/issues). Please note GitHub is not a support forum, and issues that aren't properly qualified as bugs will be closed. ### Credits * PHP CSS Parser library used https://github.com/sabberworm/PHP-CSS-Parser - License URI: https://github.com/sabberworm/PHP-CSS-Parser?tab=MIT-1-ov-file (PHP-CSS-Parser is freely distributable under the terms of an MIT-style license.) * CSS from HTML extractor library used https://github.com/JanDC/css-from-html-extractor - License URI: https://github.com/JanDC/css-from-html-extractor?tab=License-1-ov-file (CSS from HTML extractor is freely distributable under the terms of an MIT-style license.) * WebP Convert library used https://github.com/rosell-dk/webp-convert - License URI: https://github.com/rosell-dk/webp-convert?tab=MIT-1-ov-file (WebP Convert is freely distributable under the terms of an MIT-style license.) == Changelog == = 1.0.19 (07 May 2024) = * Fixed: Cant over ride the width of .cwvpsb_iframe due to the important property used #132 * Fixed: Compatibility with PHP 8.3 version #140 * Test: Test with new version of wordpress i.e. 6.5v #139 * Fixed: PHP Warning: Undefined variable $img_srcset #141 * Improvement : Option to exclude lazyloading #91 = 1.0.18 (27 February 2024) = * Fixed: CSS break after latest update (1.0.17) #130 * Fixed: Displaying unknown characters #133 * Improvement: Improvement in Image lazy load #131 * Improvement: Image optimization not working if html contain invalid DOM #134 = 1.0.17 (19 January 2024) = * Fixed: The type attribute is unnecessary for JavaScript resources. #123 * Fixed: Element script must not have attribute defer unless attribute src is also specified. #122 * Added: Option where we can set different delay JS methods on mobile and desktop. #119 * Added: Option for flush cache on a predefined schedule. #120 * Added: Option to keep cache for a long period of time. #121 * Improvement: Automatic Resizing to fix Properly Size Image issue. #118 * Fixed: Network deactivate is not working #126 * Improvement: Code Improvement #125 * Improvement: Bulk convert to webP #127 = 1.0.16 (15 November 2023) = * Fixed: Robots.txt error appears when you we enable our CWV plugin. #114 * Fixed: wp-content/gravatars folder not removed upon uninstall #112 * Fixed: Uninstall.php only removes main critical URLs table from database in multisite #111 * Improvement: Updated settings link #113 * Compatibility: Checked compatibility with wordpress v6.4 #115 = 1.0.15 (22 September 2023) = * Added: Compatibility with MYSQL v5.5 #97 * Fixed: Fatal Error on Multisite Activation: is_plugin_active_for_network() Undefined #106 * Fixed: Youtube embed video Not showing in AMP #105 * Improvement: Cache is off but still in header it's showing clear cache #104 = 1.0.14 (17 August 2023) = * Fixed: Parse error unexpected ')' #87 * Fixed: Error in core-web-vitals-pagespeed-booster Plugin. #99 * Fixed: Compatibility with 10Web Booster #96 * Improvement: Added newsletter form #4 * Improvement: WordPress 6.3 compatibility check #100 * Improvement: Improved and optimized the code according to WP standards #101 = 1.0.13 (03 June 2023) = * Improvement: Improved CSS load * Fixed: Redirection Issue = 1.0.12 (14 April 2023) = * Fixed: TypeError jQuery is not a function on console #84 * Fixed: Google fonts not loading on PHP 8.0+ #83 * Fixed: Conflict with the Google reCAPTCHA v3 #82 * Fixed: Warning Undefined array key "advance_support" #80 * Improvement : Add a label to the Exclude URL box #81 * Improvement : Exclude Google analytics from js delay #62 = 1.0.11 (17 February 2023) = * Fixed: Woocommerce payment page is not working. #77 * Improvement : Remove plugin dependency from file_get_contents function #78 = 1.0.10 (02 February 2023) = * Improvement: Optimized code and fixed frontend js issue Full changelog available at [changelog.txt](https://plugins.svn.wordpress.org/core-web-vitals-pagespeed-booster/trunk/changelog.txt)
Need to add exclude section in JS optimization, as we have in CSS.
Feed not working, issue recreated on localhost
Feed is working when our plugin is deactivated https://prnt.sc/vObtNnE1E9N9
Feed is not working when our plugin is activated https://prnt.sc/HUr8tq3aICxb
User Manoj Jadhav
Helpscout URL https://secure.helpscout.net/conversation/1763765251/#thread-5183933657
The Ads are loading but the location of the ads is getting changed.
before: https://prnt.sc/26w8oha
after: https://prnt.sc/26w9192
The menu button, search button, and slider button are also not working.
https://prnt.sc/26w9c0w
https://prnt.sc/26w95to
The page performance score is also not good 25+
The opportunities that are common in PSI are:
a. Eliminate render-blocking resources
b. Reduce js and CSS
c. Server images in next-gen formats.
Remove Unused CSS option when enabled the score on PSI is 80+
with these common opportunities:
----- Ahmed
The ads are not loading.
Before https://prnt.sc/uBdep2iTTwyc
After https://prnt.sc/sBxgAx19NvW4
An article also not loading.
Before https://prnt.sc/m6jdOpS7csWm
After https://prnt.sc/hOBY8V-6-z2U
On PSI, the result is appearing neither on Mobile nor on Desktop
Before our plugin, the common opportunities were:
If the image optimization is Automatic Mode then images are failing.
And if we put it on manual mode and click on bulk convert then the image is not getting optimized and also not appearing webp format.
Also if the lazy load is enabled then the image is not appearing.
Reference Ticket: https://secure.helpscout.net/conversation/1764866241/223070?folderId=1060554
[26-Oct-2021 04:53:04 UTC] PHP Warning: Undefined array key "lazyload_option" in C:\xampp\htdocs\wp\wp-content\plugins\core-web-vitals-pagespeed-booster\includes\admin\settings.php on line 122
[26-Oct-2021 04:53:25 UTC] PHP Warning: Undefined array key "unused_css_option" in C:\xampp\htdocs\wp\wp-content\plugins\core-web-vitals-pagespeed-booster\includes\admin\settings.php on line 138
[26-Oct-2021 04:53:25 UTC] PHP Warning: Undefined array key "fonts_option" in C:\xampp\htdocs\wp\wp-content\plugins\core-web-vitals-pagespeed-booster\includes\admin\settings.php on line 146
Issues with our plugin on the English site, when enabling the Remove Unused CSS option
The paragraph below the images is not loading and the image size has also been increased.
Before https://prnt.sc/YJbgVAPLAJiZ
After https://prnt.sc/lsSBoQbwrF8t
The Menu and the Search Buttons are not working, and the most viewed stories are not loading.
Before https://prnt.sc/n1BO0m9Y8DU1
After https://prnt.sc/aAAuAhmVUs8Q
When hovering on the menu bar the background color changes to black which is not happening and the images and the paragraph are not loading properly.
Before https://prnt.sc/p6LXqS5v9XAy
After https://prnt.sc/xNGeaYerHGgN
And for Poor URLs, the page score is 90+ with three common opportunities:
------- Ahmed
add make better auto email user feedback on plugin deactivation.
Reference ticket: https://wordpress.org/support/topic/multiple-improvement-required/
Critical Error with PHP version 8.0.17
Recreated on localhost: https://prnt.sc/LvDKrolqEYto
Benjamin user facing this issue
Need to Add mem cache compatibility
Website Url - https://sibylle-rettenmaier.de/
Helpscout URL - https://secure.helpscout.net/conversation/1746882336/221605?folderId=5044124
Page score when our plugin is activated is 85+ and when deactivated then the score is 45+
Opportunity, when our plugin is activated:
a. Serve images in next-gen formats
b. Reduce unused CSS
c. Eliminate render-blocking resources
d. Properly size images
Gallery image is not working on the single product page.
https://prnt.sc/5FF4rbacJrRt
Elemento is loading now but the banner image is not loading and the layout is totally wrong when our plugin is activated
Elemento URL : https://sibylle-rettenmaier.de/wp-admin/post.php?post=6&action=elementor
Plugin Deactivated https://prnt.sc/nHkwC3ko6Rds
Plugin Activated https://prnt.sc/6HzRAYXsVJi9
----- Ahmed
Reference Screenshot: https://prnt.sc/4SLl1bNqU6r4
check built-in gzip testing
Please follow the naming conventions showed in the WP Documentation
https://make.wordpress.org/core/handbook/best-practices/coding-standards/php/#naming-conventions
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/web-vitals-page-speed-booster.php#L32
Single Quote in the Hook add_action('plugins_loaded', 'initiate_web_vital');
Why we are using web_vital
everywhere while our plugin name is web_vitals
?
Same with the Constant Names WEBVITAL_PAGESPEED_BOOSTER_FILE
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/web-vitals-page-speed-booster.php#L17
Function names: web_vital_defaultSettings
has to be like this -> web_vitals_default_settings
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/web-vitals-page-speed-booster.php#L24
Incorrect naming convention for Variables $webVital_settings
has to be like $web_vitals_settings
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/web-vitals-page-speed-booster.php#L23
Incorrect naming convention for Class name webVitalHelperSection
has to be Web_Vitals_Helper_Section
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/web-vitals-page-speed-booster.php#L42
Function name converttoWebp
-> convert_to_webp
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/helper-section.php#L3
Same with doUploadWithWebp
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/helper-section.php#L22
Incorrect Spacing and Tabbing https://monosnap.com/file/vXcYJ70yUdhhZ8qBXCNumizEu1qxoy
Class name incorrect in multiple instances https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/admin-section.php#L2
Remove unused code https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/admin-section.php#L62
webvital_dashboard_section
-> web_vitals_dashboard_section
https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/admin-section.php#L50
Escaping URL missing: https://github.com/ahmedkaludi/web-vitals-page-speed-booster/blob/master/inc/admin-section.php#L171
Need to to Add development Mode
— ezoic
img optimization should run in a framed area, like how it shows in the error log, instead of going till the end of the page
media lib in switch to list should not show thumbnails from CWV optimized imgs https://monosnap.com/file/A0c0a62IPkeEI4Cmw98azStwpj3xnS
after saving manual method it doesn't show the options
image is streched because of width / height tags, it should have width auto https://monosnap.com/file/JuCn52XXRs7sagJS0Jl9dNk96oMwLh
img not showing, only lazy load blank pixel is showing: https://monosnap.com/file/hCmjfSyL0NmIEM3DzyhZHTGKvHxxLj
if the optimized image is not found, it should switch to unoptimized version,
progress bar
individual imgs should have an option to do optimization
Need to change the method of lazy loading of images, as it is conflicting with our js optimization method
Reference URL: https://www.tempertemper.net/blog/lazy-loading-images-without-javascript
Reference Ticket: https://secure.helpscout.net/conversation/1710671894/218740/
Need to make a module where we can test all optimization on a particular URL. Then can deploy on the whole website.
Improvement in source, create/add security endpoint in code
Need an off option where we can off the js optimization.
field to add specific IP and region.
REF: https://secure.helpscout.net/conversation/1641831630/213868?folderId=1060556
menu not working
https://prnt.sc/26w0wnt
https://prnt.sc/26w10ht
if we click on cmnt box the cmnt box is breaking
https://prnt.sc/26wtvr0
Mobile mode menu not working
https://prnt.sc/fq5MWmsgttnq
on psi
Eliminate rendered blocking
Reduced unused js
--- Ahmed
JS optimization not working
Menu not working
recommended options should be on by default
small CSS issue
Menu not working
Search Button not working
language Toggle issue
https://prnt.sc/26wto38
Check the screenshot https://prnt.sc/26omno5 this complete section is not appearing
CSS issues
Before active: https://prnt.sc/26xk07t
After active: https://prnt.sc/26xjyso
https://prnt.sc/26xk1y8
https://prnt.sc/26xk41b
Blank space issue before the ads
https://prnt.sc/26xk2v9
On PSI Reduce unused JavaScript
AMP Validation errors
update the plugin description
Search Button and Navigation Button are not working https://prnt.sc/26w5loz
Twitter Embedded video not loading https://prnt.sc/26w5myp
And images are not converting into WebP format
Common opportunities on PSI :
a. Reduce unused javascript and CSS
b. Eleminate Render-Blocking Resources
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.