diff --git a/functions.php b/functions.php index 9e88a91..a404563 100644 --- a/functions.php +++ b/functions.php @@ -335,6 +335,63 @@ function argon_frontend_hot_reload_notice() { } add_action('wp_footer', 'argon_frontend_hot_reload_notice'); +// 前端自动刷新脚本 +function argon_hot_reload_auto_refresh_script() { + if (get_option('argon_enable_hot_reload', 'false') != 'true') { + return; + } + if (get_option('argon_hot_reload_auto_refresh', 'false') != 'true') { + return; + } + + $current_version = $GLOBALS['theme_version']; + ?> + + + + + +

+ + +