import cookieConsent from './src/js/cookieconsent_v2'; // path may depend on your installation
var ccObjOverride = {}; // can override all given options in cookieConsent object
document.addEventListener('DOMContentLoaded', cookieConsent.onFirstLoad);
cookieConsent.initialise(ccObjOverride);<script src="./dist/js/cookieconsent_v2.min.js"></script>
<script>
var ccObjOverride = {}; // can override all given options in cookieConsent object
document.addEventListener('DOMContentLoaded', cookieConsent.onFirstLoad);
cookieConsent.initialise(ccObjOverride);
</script>@import 'cookieconsent_v2.scss';<link rel="stylesheet" href="./dist/css/cookieconsent_v2.min.css">- For changing and compiling SCSS and JavaScript we need to work with webpack.
navigate to root folder where
package.jsonis located and type in:
npm installObviously we need Node.js and npm installed on our machine.
Now webpack needs to be triggered to watch the specific files. Therefore use:
npm run watcherWebpack will now watch all of the files in the subfolder scss and js and will compile them to a browser ready
file you're NOT allowed to change anymore!
The compiled files will be placed inside dist/css and dist/js.
IE / Edge |
Firefox |
Chrome |
Safari |
iOS Safari |
Opera |
|---|---|---|---|---|---|
| IE11, Edge | last 5 versions | last 5 versions | last 2 versions | last 2 versions | last 5 versions |





