$ .fn.modal.noConflict is not a function - how to fix it?

  • 0
    Given: web shop on Magento 2, there is a link / links on click on each page that open a modal window.
    On some pages, it is not clear yet why, modal windows did not open, the error in the console was as follows:

    Uncaught TypeError: f [b] is not a function

    Here suggested a solution to the problem - add the noConflict method

    $ .fn.bsModal = $ .fn.modal.noConflict ();

    After that, modal windows magically work on problem pages without problems, but another error appeared in the console:

    Uncaught TypeError: $.fn.modal.noConflict is not a function

    And although this error does not affect functionality, I want to figure out why it is at all?
    JavaScript Adalaide Howard, Sep 22, 2020

  • 0 Answers
Your Answer
To place the code, please use CodePen or similar tool. Thanks you!