TyMaszWeb / django-cookie-law

Helps your Django project comply with the EU cookie regulations by displaying a cookie information banner until it is dismissed by the user
BSD 2-Clause "Simplified" License
140 stars 69 forks source link

Reject cookies #69

Closed selectnull closed 3 years ago

selectnull commented 3 years ago

This pull request adds the ability to implement rejectable cookies. That way a web visitor can choose to accept or reject the cookies and based on that, the developer can choose to load or not load the tracking code or whatever they need.

The feature added is completely backward compatible, I have added the new templates that show how to implement it. That makes it a little bit more complicated, but I think that backward compatibility is important. If you think that these changes are worth it and they should become default, I'm willing to work on that as well (as it is certainly the case that documentation can be improved).

I do not claim that this makes the app GDPR/PECR completely compliant, but it does make it more compliant that it was before.

piotrkilczuk commented 3 years ago

Thank you @selectnull and sorry for not getting back to you earlier. I'll try to have a look at this in early August and hopefully get it merged.

selectnull commented 3 years ago

@piotrkilczuk Thank you. If you want to discuss the changes or feel that there is more to be done, feel free to contact me. I already use these changes in production and would very much like to see them merged and published to pypi.

piotrkilczuk commented 3 years ago

I think this is an awesome contribution @selectnull . Thank you again.

Gonna run some checks locally and then hopefully merge.

piotrkilczuk commented 3 years ago

Released as https://pypi.org/project/django-cookie-law/2.1.0/