- This topic has 14 replies, 4 voices, and was last updated 6 years, 3 months ago by Tom.
June 16, 2016 at 2:49 am #202418Dave
Is there somewhere I can put the code from the post here into GP to make it work? In the Simple CSS plugin or in the other part (can’t remember but I think the plugin that allows code added before/after posts, pages etc…)
DaveJune 16, 2016 at 10:17 am #202494TomLead DeveloperLead Developer
I’m actually writing an article on performance in GP and some tips to get higher scores. Will hopefully have it done soon 🙂June 17, 2016 at 2:41 am #202699Dave
Great// can’t wait to read that!August 10, 2016 at 2:56 pm #217258Suzanne
Any news on the performance article?August 10, 2016 at 2:57 pm #217259TomLead DeveloperLead DeveloperOctober 6, 2016 at 8:09 pm #233044Bin
Hello, Tom. Your recommendation regarding .js files is “defer parsing”. Would you even recommend to put ALL GP .js files into the footer? And what about the css files, where is the best place for them (header or footer)? I’m using Total Cache (not autoptimize) … Good Night, Bin!October 6, 2016 at 11:00 pm #233064TomLead DeveloperLead Developer
All GP JS files are added to the footer.
jquery.js is the only file that should appear in the header, this is because it’s required for a lot of plugins that might not list it as a dependent (GP does).
CSS should be included in the header, as it should load before the structure of the site in order to avoid any flashing of styles.
Let me know if you need more info 🙂October 7, 2016 at 6:58 am #233175Bin
OK. So I put these files into the header
and all the rest .js goes to the footer (before /body>), right?
Shall I use combine only with Default Blocking OR better with DEFER operation?
Regards, BinOctober 7, 2016 at 8:52 am #233213TomLead DeveloperLead Developer
You shouldn’t have to put files anywhere – they should be there by default.
Defer should work just fine for those two files 🙂October 7, 2016 at 9:31 am #233239Bin
Yes, thats right. But I want to combine these 11 GP .js files in just ONE file by using the minify option of W3 Total Cache. I’m using “Combine only” because they are alrdeady minified (by your great effort!). My question is now, if it’s better to set this comined.js file as ASYNCH, DEFER or BLOCKING? BinOctober 7, 2016 at 9:33 am #233244TomLead DeveloperLead DeveloperOctober 7, 2016 at 9:35 am #233245Bin
Sorry, and what about:
Header or footer?October 7, 2016 at 9:42 am #233258TomLead DeveloperLead DeveloperOctober 8, 2016 at 6:59 am #233505Bin
TOM, you are the best!
BinOctober 8, 2016 at 8:09 am #233511
- You must be logged in to reply to this topic.