Why my JavaScript changes do not take effect?


EatLand uses Require.js as JavaScript module loader. So inside your template you have two main JavaScript files.

  1. script.js - it's a config file that will load all defined JS modules through AJAX. Used in development.
  2. script.min.js - it's already all the JS modules concatenated and minified (compiled version of all the modules). Used in production.

So if you want your changes to take effect, please make sure that at the end of your HTML file is included the 'script.js' instead of 'script.min.js'.

And once you have finished the development process, it's recommended to recompile all the scripts into one single file, that will reduce the number of requests and your page will load even faster. And of course don't forget to update you HTML file by setting the source of the script back to 'script.min.js'.


Last update:
2015-09-29 16:22
Author:
Vlad Sargu
Revision:
1.1
Average rating:0 (0 Votes)