Skip to main content

commonsjs-cannot-read-property-call-of-undefined

commons.js Cannot read property 'call' of undefined​

commons.js:55 Uncaught TypeError: Cannot read property 'call' of undefined

If you see this error or a similar error, you are not including the common chunks correctly in your html file. = javascript_pack_tag "commons" is an example of including commons.js chunk in app/views/layouts/application.html.haml

config/webpack/shared.js is a good place to look at all the chunks and determine which chunk you need. More about chunks - how and why our code base in chunked is mentioned here -> https://github.com/superpowr/powr/wiki/Common-Chunks,-Manifest.json,-Including-css-from-a-node-module