Better requirejs usage on the front-end