Updating Foundation in an Existing NOUVEAU Project

Since NOUVEAU is a starter theme, not a parent theme, there’s no automatic WordPress admin update when a new version comes out. So what do you do if you are working on a NOUVEAU project and you want to update to the latest, greatest version of Foundation?

I have good news: updating Zurb Foundation 5 in your NOUVEAU project a very simple process, since everything is kept separate, tidy, and modular. Here’s how you do it…

Updating Foundation

Since Foundation is a pure front-end framework, it’s been kept conveniently separate from the rest of the NOUVEAU framework (hurrah for modularity!). All the core Zurb Foundation files (Javascript, CSS, SCSS, etc) can be found in the _foundation folder of your theme. Better yet, as of NOUVEAU Theme Framework 0.9.10 (June 11, 2014), all the key, minified source files are enqueued or compiled directly from the appropriate places in the _foundation/bower_components folder. This makes updating Foundation in an existing NOUVEAU project a breeze.

Using Bower to Update

In most cases, to get the latest version of Foundation, all you need to do is run a bower update from your theme’s _foundation folder. This is usually as simple as opening a command prompt (e.g. Terminal) and typing:

  1. $ cd /path/to/your/themes/_foundation/
  2. $ bower update -h

Using CodeKit to Update

If you are using CodeKit, you can run the update from there instead. To do this:

  1. In your CodeKit project, select Assets.
  2. Select the Installed tab.
  3. Select the small, grey hamburger icon beside the tabs.
  4. Select “Update all installed components”.

CodeKit-Bower-Update

Additional Notes

The above steps should be all you need to get Foundation updated in most NOUVEAU projects.

In general, you will never need to update anything outside of the _foundation/bower_components/ folder… and in fact, doing so can sometimes cause things to break as NOUVEAU uses some slightly modified files under _foundation/scss.

Whenever I update NOUVEAU core, I always include the latest version of _foundation/scss/_settings.scss with the latest Foundation version – but this is rarely necessary when updating an existing project. If a major new breaking change is ever introduced, I will add directions to this blog on how to update to that version (and I’ll update the current version of NOUVEAU, of course).

Updating NOUVEAU‘s PHP

Strictly speaking, you will never, ever need to update NOUVEAU‘s PHP framework. When new features are added, they will be added as plugins… and failing that, should any major theme changes ever occur, I’ll be sure to do a writeup on this blog so you can copy the relevant updates into your project as painlessly as possible. Remember, NOUVEAU was created to be customized and modified according to your needs and whims – it’s a starting point, and was created to be flexible, well structured, and convenient, so that you wouldn’t need to update it like you would a parent theme.

If you ever find your NOUVEAU theme is hopelessly obsolete, it’s likely the year 2020, and it’s maybe time to start working on something new.

Scary Miscellaneous Warnings

I probably don’t have to tell you this, but you should really backup your files before doing this. Just in case.

After doing the update, check your project to ensure everything still works and you’re not getting any 404 errors from the enqueued files. On the off-chance you do see some 404s after an update, it means that the location of some pre-minified files have changed inside _foundation/bower_components/ – find the new location and then update NV\Config::enqueue_assets() with the new paths. It’s that simple!

No comments yet!

Leave a Comment

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>