Included JS Files in Production

I have included a JS files like this In my dev environment it works ok with the include statement replaced by the content of the js file. However in the production it is not working, the include statement is displayed as it causing the error Uncaught SyntaxError: Unexpected token %.
I have tried bench update --build with no effect.

Any advice?