Adding /js/ folder to watcher task excluding theme.js and theme.min.js

This commit is contained in:
koenemann 2017-02-10 08:53:41 +01:00
parent 2c01290ced
commit 6ca1abff08
3 changed files with 25 additions and 4 deletions

View File

@ -103,7 +103,7 @@ gulp.task('sass', function () {
gulp.task('watch', function () {
gulp.watch('./sass/**/*.scss', ['sass']);
gulp.watch('./css/theme.css', ['cssnano']);
gulp.watch([basePaths.dev + 'js/**/*.js'], ['scripts'])
gulp.watch([basePaths.dev + 'js/**/*.js','js/**/*.js','!js/theme.js','!js/theme.min.js'], ['scripts'])
});

View File

@ -5379,3 +5379,24 @@ var Popover = function ($) {
}, false );
}
})();
/**
* This file adds some LIVE to the Theme Customizer live preview. To leverage
* this, set your custom settings to 'postMessage' and then add your handling
* here. Your javascript should grab settings from customizer controls, and
* then make any necessary changes to the page using jQuery.
*
* @see https://codex.wordpress.org/Theme_Customization_API#Part_3:_Configure_Live_Preview_.28Optional.29
*/
( function( $ ) {
// Update the site title in real time...
wp.customize( 'blogname', function( value ) {
value.bind( function( newval ) {
console.log(newval);
$( '.navbar-header a' ).html( newval );
} );
} );
} )( jQuery );

6
js/theme.min.js vendored

File diff suppressed because one or more lines are too long