Skip to content

Instantly share code, notes, and snippets.

@paulhhowells
Last active December 16, 2015 11:49
Show Gist options
  • Save paulhhowells/5430251 to your computer and use it in GitHub Desktop.
Save paulhhowells/5430251 to your computer and use it in GitHub Desktop.
namespace with jQuery on ready
var phh = phh || {};
// jQuery closure
(function ($) {
// ready
$(function () {
if (phh.options) {
$.extend(true, phh.prefs, phh.options);
}
phh.init();
});
phh.prefs = {
key : 'value'
};
phh.init = function () {
};
}(jQuery));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment