I'm aware of a similar question here: What are the benefits of using wp_enqueue_script?What are the benefits of using wp_enqueue_script? -
However, what differs is I'm talking about a site with a pre concatenated/minified stylesheet and site scripts. I only load two js files and one css file. The two JS files are main.js (which contains all general scripts such as toggles, etc) and plugins.js which contains all js plugins I've used. They're both loaded at the end of the document in the footer. I have full control of the theme (from scratch), all plugins and I manually control js/wp plugins.
I do still enque jQuery.
So is there still any benefit to enqueuing scripts when I'm doing it this way?
Edit for answer:
- I'm controlling the JS of *JS* plugins, like velocity, retina.js, etc.
- If you're editing my code, the css is in the single css file, the js is in a single js file, if it's a (js)plugin, put it in plugins.js.
- The themes are created in such that clients don't add plugins, limited wp-admin.
- Dependencies are irrelevant, the only one is jQuery, which is the only one I load with WP.
- No need for versioning, or haven't had to so far.
- With minimal, minified JS, it's better to load all in one gzipped file than multiple http requests.
If I didn't use a plugins.js file for all the js plugins, then there would be multiple http requests done by wp, or if I used a caching plugin I'd have to piss about refreshing the cache while editing. I'm not saying you're wrong, I'm just saying none of those reasons really help. As far as I can tell...