While I was creating a theme for WordPress and got to editing the menu, I see that the menu does not work, so after checking the console log I notice that foundation.min.js has a problem with Unexpected end of script
What can cause this type of error:
Unexpected end of script
I read where he says, because you have no end }); but this is not my case since I am reloading foundation.min.js
This problem also interferes with another aspect of the foundation, and another error also occurs in the console log.
ReferenceError: Cannot find variable: Foundation
TypeError: undefined is not a function (evaluate to 'jQuery (document) .foundation ())
This issue also started when I started using AWS Cloudfront (but I doubt it could be a problem)
Image errors:

Base 5 Line Image Error:

source share