chrisdhaan / CDMarkdownKit

An extensive Swift framework providing simple and customizable markdown parsing.
MIT License
254 stars 65 forks source link

Asynchronous images #17

Open JBKaloya opened 5 years ago

JBKaloya commented 5 years ago

What did you do?

I have images that are between some paragraphs in my markdown code

What did you expect to happen?

I want to load asynchronously my images. I've tried to change the match function with a DispatchQueue.main.async in the CDMarkdownImage.swift but it doesn't display the images at all.

What happened instead?

The images are loading well but they are synchronized with the rest of the rendering. The view takes a while to load.

CDMarkdownKit Environment

CDMarkdownKit version: 1.0 Xcode version: 10.1 Swift version: 3 Platform(s) running CDMarkdownKit: IOS macOS version running Xcode:10.14.3

chrisdhaan commented 5 years ago

@JBKaloya this is a good feature request. Though I have a lot going on right now and am not sure when I will get around to attempting to implement it. Feel free to fork and continue trying on your own. But it realistically may be a few weeks until I give this a try.

JBKaloya commented 5 years ago

Thanks for your prompt reply! I will definitely keep you updated if I manage to implement this enhancement on my own.

rizwan95 commented 4 years ago

This is a much-needed requirement!! @JBKaloya @chrisdhaan