Approach to offer a generic tooling for GDPR-compliant cookie handling. Use @ckies/library
in your JavaScript or TypeScript projects, or use it as a drop-in solution for static projects.
Per default, opt-out is used and all cookies are allowed. Set window.CKIES_OPTIN
to true
and all cookies but necessary ones are denied per default.
import { ckies } from '@ckies/library'
if (ckies.useMarketing()) {
console.log('Marketing cookies are allowed!')
}
<script src="ckies.min.js"></script>
<script>
if (ckies.useMarketing()) {
console.log('Marketing cookies are allowed!')
}
</script>