Giter Club home page Giter Club logo

Comments (8)

06chaynes avatar 06chaynes commented on July 21, 2024 1

from http-cache.

06chaynes avatar 06chaynes commented on July 21, 2024

I ran into issues trying to get this to work with the reqwest client implementation, I have some of that detailed here in this PR seanmonstar/reqwest#1920. Basically I was unable to build a response. I also wasn't able to get Surf to build for wasm on my Mac at all and wasn't interested in troubleshooting that at the time.

Best of luck if you wish to tackle this, I'll help where I can. That said I do not plan on working during the holidays so I may not be as responsive till after the new year.

from http-cache.

ssddOnTop avatar ssddOnTop commented on July 21, 2024

@06chaynes I don't think we need to convert that to web_sys::Response (our current implementation is solely based on reqwest and hyper) but I think the problem lies in caching

from http-cache.

06chaynes avatar 06chaynes commented on July 21, 2024

I think you may be missing my point. I have to create a reqwest response to return, I was unable to do that using the wasm::response::Response type in reqwest

from http-cache.

ssddOnTop avatar ssddOnTop commented on July 21, 2024

ye I got your point, I tried that myself but failed..

understanding the implementation would take me some time but why do we require conversion from wasm::response::Response to reqwest::Response?

this is the normal implementation, and here I am trying to make client for WASM.

and they are executed here

I am confused why is the response conversion required here.. and can you give some possible solution (may be custom implementation) to cache responses

from http-cache.

06chaynes avatar 06chaynes commented on July 21, 2024

Just a note that I removed the bounty from the issue title as I do not want to confuse others into thinking that I am offering that bounty or that I can enforce that in some way.

from http-cache.

ssddOnTop avatar ssddOnTop commented on July 21, 2024

@06chaynes apart from the conversion from reqwest::wasm::Response to http::Response I think we will need to use some other way to cache that works with wasm right? Do you have any idea for that?

from http-cache.

06chaynes avatar 06chaynes commented on July 21, 2024

Once the response can be created there's really only the backend cache manager implementation left to add, as the changes to the core library are fairly straightforward.

I had started on some of the core library changes in a branch here though now it's out of date https://github.com/06chaynes/http-cache/tree/wasm32.

As for the backed cache manager I was thinking of testing out some of the crates made for working with IndexedDB but didn't get that far after running into to the client side issues.

from http-cache.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.