© 2026 LinearBytes Inc.
Search posts, tags, users, and pages
Thorvald
Hey, This works fine for me but what if I wanted to return it directly from a browser? I'm really struggling as to how to return a file to a browser since the accepted-header isnt set. "Object has no attribute accepted_renderer"
Harsha N Hegde
Builder. Occasionally ruins bad ideas.
Hey Thorvald , It would depend on your front end code. Have you tried: github.com/eligrey/FileSaver.js ?
Hey, I ended up solving it by changing one of the headers. Made a SO post about it, the solution isn't optimal but works fine :) stackoverflow.com/questions/65865390/django-rest-…