alexedwards / scs

HTTP Session Management for Go
MIT License
2.12k stars 165 forks source link

Flush / streaming #186

Closed freimer closed 10 months ago

freimer commented 10 months ago

It does not appear that this supports streaming, or the ability to flush the writer. The sessionResponseWriter is not exported (lowercase), so we can't get at the underlying ResponseWriter (w), nor can we call the Unwrap (because we would need to type assert and we can't because sessionResponseWriter is not exported. So bit of a quandary here, unless I'm just missing something. Would it be possible to implement http.Flusher?

freimer commented 10 months ago

Read #141 and implemented the ResponseController. Everything works. I suggest some (prominent) note be added in the docs. Either it is not there, or I missed it. Feel free to close this issue, leaving it open so the request to put in docs is noticed...

alexedwards commented 10 months ago

Done! https://github.com/alexedwards/scs#flushing-and-streaming-responses

Thanks for the suggestion :+1: