简体   繁体   English

加载FullCalendar> Uncaught TypeError:无法读取未定义的属性'push'

[英]FullCalendar on loading > Uncaught TypeError: Cannot read property 'push' of undefined

thanks for tyour assistance first of all. 首先感谢你的帮助。 I'm simply loading FullCalendar ( https://fullcalendar.io/ ) on my dev environemts but it doesn't seem to work. 我只是在我的dev environemts上加载FullCalendar( https://fullcalendar.io/ ),但它似乎不起作用。

When I open the console on Chrome it gives me the following issue. 当我在Chrome上打开控制台时,它会给我以下问题。

Uncaught TypeError: Cannot read property 'push' of undefined
    at fullcalendar.min.js:6
    at fullcalendar.min.js:6
    at fullcalendar.min.js:6

I haven't even called/declared the script yet and this puzzles me. 我还没有打电话/宣布剧本,这让我很困惑。

Code cut down to the essential below. 代码减少到下面的基本要素。 Thank you 谢谢

<!DOCTYPE html>
<html lang="en">

    <head>
        <title>Home</title>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="description" content="">

        <!-- CSS -->
        <link href="http://localhost/dev/assets/third-party/css/styles.css" rel="stylesheet">
        <link href="http://localhost/dev/assets/third-party/css/skins/indianred.css" rel="stylesheet">
        <link href='//cdnjs.cloudflare.com/ajax/libs/fullcalendar/3.2.0/fullcalendar.min.css' rel='stylesheet' />
        <link href='//cdnjs.cloudflare.com/ajax/libs/fullcalendar/3.2.0/fullcalendar.print.css' rel='stylesheet' media='print' />

    </head>
    <body>
        <!-- WRAPPER -->
        <div class="wrapper">
            <div id="calendar"></div>

        </div>
        <!-- END WRAPPER -->
        <!-- JAVASCRIPTS -->
        <script src='http://localhost/dev/assets/third-party/js/jquery-2.1.1.min.js'></script>
        <script src='http://localhost/dev/assets/third-party/js/bootstrap.min.js'></script>
        <script src='http://localhost/dev/assets/third-party/js/repute-scripts.js'></script>
        <script src="//cdnjs.cloudflare.com/ajax/libs/1000hz-bootstrap-validator/0.11.9/validator.min.js"></script>
        <script src='http://localhost/dev/assets/third-party/js/plugins/moment/moment.min.js'></script>
        <script src='http://localhost/dev/assets/third-party/js/plugins/fullcalendar/fullcalendar.min.js'></script>
        <script src="http://localhost/dev/assets/js/b/result.js"></script>
        <script src="http://localhost/dev/assets/js/b/event.js"></script>
        <script src="http://localhost/dev/assets/js/b/bapp.js"></script>
        <script>
            $(function() {
                var bapp = new Bapp();
            });
        </script>
        <!-- END JAVASCRIPTS -->
    </body>
</html>

I had the same error message because I using a version of moment that didn't support moment.momentProperties . 我有相同的错误消息,因为我使用的是不支持moment.momentPropertiesmoment版本。 If you point to fullcalendar.js instead of the min version, the line numbers in the error message will help you see whether or not the error originated from the same issue. 如果您指向fullcalendar.js而不是min版本,错误消息中的行号将帮助您查看错误是否源自同一问题。 I fixed it by downloading the zip file from fullcalendar and pointing to the moment.min.js file included there. 我通过从fullcalendar下载zip文件并指向其中包含的moment.min.js文件来修复它。 I was using moment version 2.0.0 . 我使用的是moment version 2.0.0 The version included from fullcalendar (downloaded today) was 2.18.1 . fullcalendar (今天下载)中包含的版本是2.18.1

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 未捕获的TypeError:无法读取未定义的属性&#39;fullCalendar&#39; - Uncaught TypeError: Cannot read property 'fullCalendar' of undefined fullcalendar.js:未捕获TypeError:无法读取未定义的属性&#39;ownerDocument&#39; - fullcalendar.js: Uncaught TypeError: Cannot read property 'ownerDocument' of undefined 流星未捕获TypeError:无法读取未定义的属性“ push” - Meteor Uncaught TypeError: Cannot read property 'push' of undefined 捕获TypeError:无法读取未定义的属性“ push” - Getting Uncaught TypeError: Cannot read property 'push' of undefined 数组:未捕获的类型错误:无法读取未定义的属性“推送” - Array: Uncaught TypeError: Cannot read property 'push' of undefined 偶尔收到“未捕获的TypeError:无法读取未定义的属性&#39;push&#39;” - Getting “Uncaught TypeError: Cannot read property 'push' of undefined” sporadically 未捕获的类型错误:无法读取 Vuejs 中未定义的属性“推送” - Uncaught TypeError: Cannot read property 'push' of undefined in Vuejs Javascript Uncaught TypeError:无法读取未定义的属性“推送” - Javascript Uncaught TypeError: Cannot read property 'push' of undefined 变量问题:未捕获的TypeError:无法读取未定义的属性“推” - variable problem: Uncaught TypeError: Cannot read property 'push' of undefined 类型错误:无法读取未定义 Fullcalendar 的属性“resourceAreaWidth” - TypeError: Cannot read property 'resourceAreaWidth' of undefined Fullcalendar
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM