Object doesn't support property or method 'DataTable'
Object doesn't support property or method 'DataTable'
Dear support team,
I am trying to use DataTables plugin in my existing application. But I am getting the following error on the JavaScript console.
SCRIPT438: Object doesn't support property or method 'DataTable'
I have created the following fiddle for you to look into. It's a simplified version my application code.
https://jsfiddle.net/fxg3zcu5/23/
As you can see, at the bottom of the Scripts section, I have a long third party minified scriptlet. If I remove that. the table appears correctly. My application includes this script with a script tag. E.g.
But unfortunately, I don't have a control over changing this scriptlet. How can I do a workaround? What has DataTable anything to do with this scriptlet?
Regards,
Viral S
This question has an accepted answers - jump to answer
Answers
I was able to resolve this issue by using RequireJS to load the DataTables script rather than using the <script> tag.