0

在控制台中写道:

uncaught reference error.

请告诉我,错误在哪里?

<script>
    $('select').selectric({
    maxHeight: 200
    });
    $.noConflict();
</script>
4

1 回答 1

0

我认为这段代码可以避免错误:

<script>
    $.noConflict();
    $(function () {
        "use strict";

        if (typeof($.selectric) === "function") {
            $("select").selectric({
                maxHeight: 200
            });
        }
    });
</script>
于 2019-01-17T18:00:12.000 回答