Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
I would advise against this, loading in the files in PHP and outputting them in PHP on each page load will take longer and wipe out any savings you make. It will not speed up your sites frontend transfer. Doing it reliably also means using an output buffer to store the entiire page, crippling time to first byte and time to first render, and eliminating progressive rendering in the browser, making your site appear slower, and giving potential SEO penalties.
You could overwrite wp_enqueue_script to modify the minify Code. But it would more slowly that It has to be load the whole script then could compress your code.
wp_enqueue_script
to modify the minify Code. But it would more slowly that It has to be load the whole script then could compress your code.