This plugin is for somehow and for some reason loading the back end gutenberg editor scripts/styles on the front end, causing pretty severe pagespeed score reductions.
Here are some stats for a page without any charts on it:
125 requests
22.42 MB / 21.53 MB transferred
Finish: 3.16 s
DOMContentLoaded: 1.62 s
load: 2.71 s
After disabling the plugin:
76 requests
13.39 MB / 12.51 MB transferred
Finish: 2.31 s
DOMContentLoaded: 882 ms
load: 1.88 s
I believe it has something to do with including backend editor assets because, for instance, it is causing a call to https://{{website}}/wp-json/wp/v2/users/me?context=edit&_locale=user on every page, which results in a 401 error.
]]>Running WordPress 5.8.1, I am getting the following errors in the javascript console when viewing a page that uses the pie chart block. The chart is not rendering and is instead loading as a blank canvas element.
The block "charts-blocks/bar" is registered with an invalid category "charts-blocks".
ve @ blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2
blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2 The block "charts-blocks/pie" is registered with an invalid category "charts-blocks".
ve @ blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2
blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2 The block "charts-blocks/doughnut" is registered with an invalid category "charts-blocks".
ve @ blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2
blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2 The block "charts-blocks/line" is registered with an invalid category "charts-blocks".
ve @ blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2
blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2 The block "charts-blocks/horizontal-bar" is registered with an invalid category "charts-blocks".
ve @ blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2
blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156:2 The block "charts-blocks/horizontal-line" is registered with an invalid category "charts-blocks".
]]>
First of all, this plugin is fantastic. Great work!
Is there a way to adjust the default colors to match the theme colors?
Also, I noticed that when a chart is added within a Group or Column block in Gutenberg, it gives these warnings:
Notice: Undefined index: align in /app/public/wp-content/plugins/charts-blocks/charts-block.php on line 58
Notice: Undefined index: align in /app/public/wp-content/plugins/charts-blocks/charts-block.php on line 60
]]>