最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

jquery - error: n.imagesLoaded is not a function

programmeradmin2浏览0评论

I have converted a template to wordpress format. and added styles and scripts in functions.php. but i keep getting error

snow.min.js:11 Uncaught TypeError: n.imagesLoaded is not a function
    at HTMLDivElement.<anonymous> (snow.min.js:11)
    at Function.each (jquery.min.js:2)
    at w.fn.init.each (jquery.min.js:2)
    at e.t.initPluginIsotope (snow.min.js:11)
    at e.value (snow.min.js:11)
    at e.value (snow.min.js:11)
    at Object.<anonymous> (snow-init.js:154)
    at __webpack_require__ (snow-init.js:30)
    at Object.<anonymous> (snow-init.js:140)
    at __webpack_require__ (snow-init.js:30)

my functions.php consists of

function evend_header_files() {
    wp_enqueue_style('university_gibberish_styles', get_stylesheet_uri(), NULL);
    wp_enqueue_style('custom-file', get_parent_theme_file_uri('/assets/css/custom.css'), NULL, microtime(), False);
    wp_enqueue_script('jquery1', get_parent_theme_file_uri('/assets/vendor/jquery/dist/jquery.min.js'),NULL, microtime(), False);
}

add_action('wp_enqueue_scripts', 'sevend_header_files');

and

function sevend_footer_files() {
   wp_enqueue_script('isotope-file', get_parent_theme_file_uri().'/assets/vendor/isotope-layout/dist/isotope.pkgd.min.js',  array('jquery1'), microtime(), True);
    wp_enqueue_script('snow_min-file', get_parent_theme_file_uri().'/assets/js/snow.min.js', array('jquery1', 'isotope-file'), microtime(), True);
    wp_enqueue_script('snow-init-file', get_parent_theme_file_uri().'/assets/js/snow-init.js', array('jquery1', 'isotope-file'), microtime(), True);

}

    add_action('wp_enqueue_scripts', 'sevend_footer_files');

Require help.

The website template works fine in static with no errors but i keep getting errors in wordpress template.

TypeError: n.imagesLoaded is not a function and other errors too which are related to this one.

发布评论

评论列表(0)

  1. 暂无评论