How can I load scripts in a html based on the cookie value. I need to switch between development and deployment mode.
I am using wro4j but I can't find where the error comes in that wro4j grouped js files.
<head>
if (getcookie(debug-mode) load the following scripts
<script type="text/javascript" src="/assets/v/{{ASSET_VERSION}}/main-core.js"></script>
<script type="text/javascript" src="/assets/v/{{ASSET_VERSION}}/angular-core.js"></script>
<script type="text/javascript" src="/assets/v/{{ASSET_VERSION}}/angular-app.js"></script>
else load this script
<script type="text/javascript">
loadIndividualJsCssFiles('config/assets.xml');
</script>
</head>
how to acheive this