Topic: MDB + Jquery
MattyP pro asked 3 months ago
I'm trying to load Jquery [https://code.jquery.com/jquery-3.7.1.min.js] as well as [js/mdb.umd.min.js] as I'd like to run them alongside each other so that I can supply some backwards compatibility with certain features that have been developed over time. I'm getting "Uncaught TypeError: can't access property "Constructor", e.fn[i] is undefined b index.js:254"
Could you explain whether this is possible and if so how it can be done? I'm not terribly familiar with UMD and ES modules or Webpack so could you be kind?
Many thanks.
MattyP pro answered 3 months ago
I've created a Snippet [https://mdbootstrap.com/snippets/standard/mattyp/6255108]
The jquery works but throws this error (and some others to!) Uncaught TypeError: can't access property "Constructor", e.fn[i] is undefined
If you remove the jquery script then the document.ready errors with $ is not defined
If you remove the jquery script and the document.ready lines - no errors
?!
Kamila Pieńkowska staff answered 3 months ago
Those should be compatible. Do you have some code already on your site?
If so please link here a snippet with this code.Also please describe how are you doing your imports.
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Pro
- Premium support: No
- Technology: MDB Standard
- MDB Version: MDB5 8.0.0
- Device: Any
- Browser: Any
- OS: WIndows
- Provided sample code: No
- Provided link: No