Image OkHttp

WARNING

This is documentation for legacy versions. For the most current version click here.

image-okhttp

Uses okhttp library as the network transport fro images. Since 3.0.0 Markwon uses a system-native HttpUrlConnection and does not rely on any 3rd-party tool to download resources from network. It can answer the most common needs, but if you would like to have a custom redirect policy or add an explicit caching of downloaded resources OkHttp might be a better option.

final Markwon markwon = Markwon.builder(context)
        // it's required to register ImagesPlugin
        .usePlugin(ImagesPlugin.create(context))
        
        // will create default instance of OkHttpClient
        .usePlugin(OkHttpImagesPlugin.create())
        
        // or accept a configured client
        .usePlugin(OkHttpImagesPlugin.create(new OkHttpClient()))
        .build();

Proguard

-dontwarn okhttp3.**
-dontwarn okio.**
Last Updated: 8/6/2019, 7:27:20 PM