Got this problem when try to use fixed-columns extension

Got this problem when try to use fixed-columns extension

namtxnamtx Posts: 1Questions: 1Answers: 0

I got the following error when try to import fixed columns extension by

import 'datatables.net-fixedcolumns-dt';

Uncaught TypeError: webpack_require(...) is not a function
at cjsRequires (dataTables.fixedColumns.js:20:1)
at eval (dataTables.fixedColumns.js:41:1)
at eval (dataTables.fixedColumns.js:49:1)
at ./node_modules/datatables.net-fixedcolumns/js/dataTables.fixedColumns.js (app.js?.76d8f773051ad7eb1f1c:10254:1)
at webpack_require (manifest.js?.76d8f773051ad7eb1f1c:90:30)
at eval (fixedColumns.dataTables.mjs:1:1)
at ./node_modules/datatables.net-fixedcolumns-dt/js/fixedColumns.dataTables.mjs (app.js?.76d8f773051ad7eb1f1c:10232:1)
at webpack_require (manifest.js?.76d8f773051ad7eb1f1c:90:30)
at eval (imports.js:1:1)
at ./resources/assets/js/client/imports.js (app.js?.76d8f773051ad7eb1f1c:14013:1)

Any suggestion fix that?
seem require function return module, not a DataTable instance

Answers

  • allanallan Posts: 62,803Questions: 1Answers: 10,332 Site admin

    Is WebPack configured to use modules or CommonJS? If you could create a minimal repo showing the issue that would be really useful.

    Allan

Sign In or Register to comment.