Code Monkey home page Code Monkey logo

Comments (6)

alexwilson avatar alexwilson commented on May 18, 2024 1

I could see that working really well, and best of all would be framework agnostic. This kind of client-side caching seems almost like an absolute necessity when pulling information to build the state of an app, when the network can be slow or unavailable.

from reactfire.

jwngr avatar jwngr commented on May 18, 2024

Thanks for opening this issue! I'm a bit overwhelmed with other things at the moment, so give me a few days to process this and respond in full. I just wanted to let you know that I read it and am not ignoring it.

FYI, the original source code is just in a single file here. Local setup instructions are here.

from reactfire.

alexwilson avatar alexwilson commented on May 18, 2024

I think that this is an excellent idea for app resiliency (especially given the promising feature-set of GunJS!), but that if it were to exist, it should probably exist within the Firebase binding and not in ReactFire as in theory it could work without any knowledge of an implementing client.

from reactfire.

onzag avatar onzag commented on May 18, 2024

@antoligy it could be a wrapper or a plugin, like firebaseResillent = new FirebaseResillent(firebase) or something the like; where you modify the main object.

from reactfire.

onzag avatar onzag commented on May 18, 2024

@antoligy maybe we should probably bring this to the actual firebase project; rather than reactfire since that, as you say, it doesn't have to be just about ReactFire.

I'd just be more complex that way, and I don't think I could develop that on my own (considering work).

Maybe a generic wrapper would be nice, where you can say which functions do what; and make it external from firebase so that it can work with other libraries as well that use this JSON model.

from reactfire.

jwngr avatar jwngr commented on May 18, 2024

Hey there, thanks for the discussion so far. I agree that this seems like more of a thing that belongs in the core Firebase SDK, not ReactFire. Unfortunately, the core Firebase SDK is not yet open sourced, so for now, you'd have to build a wrapper around the SDK which has this behavior. Note that we have longterm plans to bring true offline persistence to the JavaScript SDK like we have with the mobile SDKs, but it is still a good deal off.

Marking as "invalid" just because this isn't the right place to introduce this kind of behavior. I definitely would love to see you make something like this, but I think it should live independent of ReactFire.

Let me know if you've got questions.

from reactfire.

Related Issues (20)

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.