semvec/pypi-packages huggingface dataset:
django-http-cache-control-view 2020.7.1
Django http Cache-Control header view mixin
License: Unlicense
Keywords: django cache-control header view

<!--
https://readme42.com
-->


[![](https://img.shields.io/pypi/v/django-http-cache-control-view.svg?maxAge=3600)](https://pypi.org/project/django-http-cache-control-view/)
[![](https://img.shields.io/badge/License-Unlicense-blue.svg?longCache=True)](https://unlicense.org/)

### Installation
```bash
$ [sudo] pip install django-http-cache-control-view
```

##### `views.py`
```python
from django_http_cache_control_view.views import HttpCacheControlMixin

class MyView(HttpCacheControlMixin,...):
    http_cache_control_max_age = 60
```

```python
class MyView(HttpCacheControlMixin,...):
    def get_http_cache_control_max_age(self):
        return 60
```

<p align="center">
    <a href="https://readme42.com/">readme42.com</a>
</p>
django-http-etag-view 2020.7.1
Django http Etag header view mixin
License: Unlicense
Keywords: django Etag header view

<!--
https://readme42.com
-->


[![](https://img.shields.io/pypi/v/django-http-etag-view.svg?maxAge=3600)](https://pypi.org/project/django-http-etag-view/)
[![](https://img.shields.io/badge/License-Unlicense-blue.svg?longCache=True)](https://unlicense.org/)

### Installation
```bash
$ [sudo] pip install django-http-etag-view
```

#### Examples
`get_http_etag`
```python
from django_http_etag_view.views import HttpEtagMixin

class MyView(HttpEtagMixin,...):

    def get_http_etag(self):
        return 'XXX'
```

`dispatch`, `self.http_etag`:
```python
class MyView(HttpEtagMixin,...):
    def dispatch(self, *args, **kwargs):
        self.http_etag = 'XXX'
        return super().dispatch(*args, **kwargs)
```

<p align="center">
    <a href="https://readme42.com/">readme42.com</a>
</p>