Topic: JS Error after MDB 5 update

riomigal free asked 3 years ago


Hello

I receive this error after updating mdb 5 npm package.

app.js?id=0ce929fc5b3814b3efb6:9182 Uncaught Error: SELECT: Option "selectAll" provided type "string" but expected type "boolean". ...

There seem to be a problem with the API options in general.

Could you please help?

Thank you


riomigal free commented 3 years ago

Could you please help? I need to fix it as soon as possible.


Grzegorz Bujański staff commented 3 years ago

I have checked it locally and unfortunately I am not able to reproduce this error. Please paste the code that causes this error here.


riomigal free commented 3 years ago

I am using the PRO Version.

I tried to import the whole library, then also just modules. The problem is that the code breaks. E.g. dropdown is working but the select multiple breaks the code.


riomigal free commented 3 years ago

The problem are those options in the Select API, if I remove them it's working else not:

data-filterdata-select-all

Example of one select...


Grzegorz Bujański staff answered 3 years ago


In version 3.0.0 there was a very important change. All JavaScript components are now namespaced to help distinguish MDB functionality from third parties and your own code. Details can be found in our changelog: https://mdbootstrap.com/docs/standard/getting-started/changelog/#v3-0-0 In this case, just use data-mdb-filter and data-mdb-select-all.


riomigal free commented 3 years ago

Thank you Grzegorz! It's working now!


Grzegorz Bujański staff commented 3 years ago

You're welcome :)


riomigal free answered 3 years ago


The error is generated by this function

.../mdb-ui-kit/src/js/pro/select/util'

function line 116: typeCheckConfig



Please insert min. 20 characters.

FREE CONSULTATION

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

Status

Resolved

Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB Standard
  • MDB Version: 3.0.0
  • Device: Notebook
  • Browser: Chrome
  • OS: Windows
  • Provided sample code: No
  • Provided link: No
Tags