Topic: mdb5 pro Cannot read property 'classList' of null

Semih Sarı pro asked 3 years ago


i have tried mdb5 pro with my gulp compiler.throws an exception (Cannot read property 'classList' of null) when imported mdb.min.js

gulp compile is succcess
[11:48:37] Starting 'default'...
[11:48:37] Starting 'clean'...
[11:48:38] Finished 'clean' after 204 ms
[11:48:38] Starting '<anonymous>'...
[11:48:38] Starting 'scripts'...
[11:48:38] Starting 'copies'...
[11:48:38] Starting 'watch'...
[11:48:38] Finished 'copies' after 31 ms
[11:48:38] Finished 'watch' after 42 ms
[11:48:44] Finished 'scripts' after 6.7 s

my gulpfile

enter image description here

enter image description here


Grzegorz Bujański staff commented 3 years ago

Have you already tried to add some component, or you have a blank page so far and this error shows up after adding mdb.min.js? Maybe try to add uncompiled files? mdb.min.js was created using the webpack. It is possible that gulp cannot cope with such a file. To be honest, we don't have any recommendations on how to prepare a gulp configuration to work with MDB5. MDB5 has been prepared in such a way that it works without any problems with the webpack. We also have a webpack starter that you can use: https://github.com/mdbootstrap/mdb-webpack-starter



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Opened

Specification of the issue

  • ForumUser: Pro
  • Premium support: No
  • Technology: MDB Standard
  • MDB Version: 3.2.0
  • Device: macbook
  • Browser: chrome
  • OS: osx big sure
  • Provided sample code: No
  • Provided link: Yes