digisavvy / some-like-it-neat

A WordPress Theme Using _s, Bourbon + Neat and Theme Hook Alliance
GNU General Public License v2.0
276 stars 61 forks source link

Javascript & Bower Dependencies #78

Closed onlyskyguy closed 9 years ago

onlyskyguy commented 9 years ago

How is the theme currently setup to use bower dependencies? I see there's a JS assets folder that gets processed by gulp, but the build task removes the bower folder... does it move the files and process them first (minify etc)?

I'd like to include some conditional scripts that only run on certain pages. I'd rather not have that code sitting in one big minified file if I used the JS Files for theme folder, which sends them to production.js.

digisavvy commented 9 years ago

The theme has three dependencies controlled via Bower: Bourbon, Neat and Bi-app-sass. Their scss files are compiled into the main site's css. So not having the bower_components folder affects nothing. However, if you wish to continue developing the theme, then you'll need to run bower install again.

As for custom JS. Any files you place in assets/js/app are concatenated and minified. So it's best to not place files there if you don't want them minified or concatenated automatically.