Comments (2)
Hello @jd-0001,
DRF means Django Rest Framework, right? if yes, it would be easy to add support to it.
The WEBPImageConverter
class is the one which does all the conversion logic, so we could add to a view or serializer to return the webp url instead of the regular image url.
To integrate in an existing project, just follow the installation guide and you will have the webp
templatetag in your django, then we can create the view/serializer
What you think ?
from django-webp.
Hi @andrefarzat it's really great that we can integrate it with DRF. Currently, we are moved to another project so can we keep it open?
Can you please provide exaple of how to use WEBPImageConverter
class how to return webp image URL through serializer.
Regards.
from django-webp.
Related Issues (15)
- move covert logic to storage HOT 1
- Update to Python 3 and Django 3 HOT 1
- Add Support For Database models.ImageField images stored in /media HOT 3
- Apple Safari / IOS Handling HOT 2
- Upload Latest Version To PyPi & Update Docs With New Feature Usage HOT 2
- Clear cache frequency recommendation? HOT 2
- Convert From Webp To Another Format? HOT 3
- PII / GDPR Question
- Use something other than SHA256?
- Cast STATIC_ROOT to string when joining WEBP_STATIC_ROOT
- Update browser support HOT 1
- WEBP image could not be saved in HOT 3
- 404 Not found error HOT 3
- can't import django-webp, ModuleNotFoundError: No module named 'utils'
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-webp.