This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function ( root, name, deps, factory ) { | |
"use strict"; | |
// | |
// export the module umd-style (with deps bundled-in or external) | |
// Get current filename/path | |
function getPath( isNode, isWebWorker, isAMD, isBrowser, amdMod ) | |
{ | |
var f; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function( root, name, factory ) { | |
"use strict"; | |
// | |
// export the module, umd-style (no other dependencies) | |
var isCommonJS = ("object" === typeof(module)) && module.exports, | |
isAMD = ("function" === typeof(define)) && define.amd, m; | |
// CommonJS, node, etc.. | |
if ( isCommonJS ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
!function( $ ){ | |
"use strict"; | |
// include modified jquery.execReeady.js RIGHT AFTER jquery script, to handle onReady as mod exec | |
// the approach taken here is this: | |
// only the absolutely necessary assets (scripts/styles) should be included in ALL pages (e.g jquery, jquery.execReday, smoothState.js, smoothState-wordpress.js) | |
// all other assets (scripts/styles) per specific page should be included INSIDE the page part handled by smoothState, this script will make sure everything will load and init as transparently as possible | |
// the smoothState container element is #page and the replaced element is #page > .site.inner which should have a class .page-transition as well | |
// the transitions are parametrisable through some global settings under window.WPSmoothStateOptions which includes duration, inTransition, outTransition classes | |
// but one can change that if one wishes, this is quite generic since i use libraries of css-based animations with lots of options, so i find this more generic and parametrisable at wil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Replace jQuery's $.fn.ready() function with a mod exec | |
* | |
* Sites that make heavy use of the $(document).ready function | |
* are generally incompatable with asynchrounous content. The | |
* the $.fn.ready function only runs once. This script replaces | |
* the ready function with a module execution controller that | |
* let's us register functions and execute all of the functions | |
* as we need them. This is useful after HTML gets injected on the | |
* page and we want to rebind functionally to the new content. |