After upgrading Magento from version 2.1.1 to 2.1.17, I am facing this error

Uncaught TypeError: require is not a function at editor.js:6

across admin area especially in edit pages

when I look at html -> head I see that js file


is called first before requirejs file

Please help


Delete the existing require js from pub/static/_requirejs/frontend/Namespace/Theme/en_US requirejs-config.js path and refresh the page again so it will regenerate it and solve the error of js not found.


Follow below steps . I think it's solve your problem

  1. Remove Your Cache
  2. Clean theme by command : grunt clean
  3. Run CMD command prompt with administrator privilege
  4. run command : grunt exec:yourthemename
  5. run command : grunt less:yourthemename
  6. run command : grunt watch

Basically working and the right solution, but with the limitations of #6367

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.