Giter Site home page Giter Site logo

Coil with caching about coil HOT 7 CLOSED

coil-kt avatar coil-kt commented on August 28, 2024
Coil with caching

from coil.

Comments (7)

colinrtwhite avatar colinrtwhite commented on August 28, 2024 5

@vegeta2102 You can disable memory caching on a per-request basis like this:

imageView.load(url) {
    memoryCachePolicy(CachePolicy.DISABLED)
}

from coil.

colinrtwhite avatar colinrtwhite commented on August 28, 2024 2

I added a section about disk caching to the FAQ here: https://coil-kt.github.io/coil/faq/#how-do-i-set-up-disk-caching

Coil does not support writing Transformations back to the disk cache - they're only cached in memory. This let's us remove a lot of complexity that exists within Glide and let's us avoid re-implementing OkHttp's disk cache.

Coil keeps an in-memory cache for BitmapDrawables, though I'm in the process of adjusting it to support all Drawables.

from coil.

isfaaghyth avatar isfaaghyth commented on August 28, 2024

are you looking for this one?
https://github.com/coil-kt/coil/blob/master/docs/faq.md

from coil.

franciscoaleixo avatar franciscoaleixo commented on August 28, 2024

Also, does Coil have a multi-layered cache and does it support transformation caching? I.e., does it ever cache to memory, besides disk? Does it cache transformed images and not just the source image? These are very important things (to me) that would be really useful (and present in Glide, for example).

If it just caches through OkHttp it might be very limiting but I'm not versed enough in their caching to know so any input is welcome.

from coil.

vegeta2102 avatar vegeta2102 commented on August 28, 2024

@colinrtwhite
I have looked into . Thanks!
https://github.com/coil-kt/coil/blob/master/docs/faq.md

btw, does Coil support setting up memory cache for specific image ?
If we configure image cache as above URL. It'll be affect all .

from coil.

lucianoluzzi avatar lucianoluzzi commented on August 28, 2024

@vegeta2102 You can disable memory caching on a per-request basis like this:

imageView.load(url) {
    memoryCachePolicy(CachePolicy.DISABLED)
}

Was looking for a way to do so.
Maybe should this be documented in the ImageLoaders or Caching part of the docs?

from coil.

davo417 avatar davo417 commented on August 28, 2024

@vegeta2102 You can disable memory caching on a per-request basis like this:

imageView.load(url) {
    memoryCachePolicy(CachePolicy.DISABLED)
}

Was looking for a way to do so.
Maybe should this be documented in the ImageLoaders or Caching part of the docs?

It is: https://coil-kt.github.io/coil/getting_started/#preloading

from coil.

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.