Topic: Datatables do not load correctly if columns name is other than "columns" in async mode

Denre priority asked 3 years ago


I expect to be able to give any name to the constant columns

Any other name stops the async table from being populated with data

https://mdbootstrap.com/docs/standard/data/datatables/ (Async data)

change const columns to const productcolumns

Same for:

const asyncTable = new mdb.Datatable( document.getElementById('datatable'), { productcolumns,


Denre priority answered 3 years ago


Using

const asyncTable = new mdb.Datatable( document.getElementById('datatable'), { columns: productcolumns,

solved my issue.



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: Priority
  • Premium support: Yes
  • Technology: MDB Standard
  • MDB Version: MDB5 3.9.0
  • Device: Laptop
  • Browser: FireFox
  • OS: Windows 10
  • Provided sample code: No
  • Provided link: Yes