Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

image with base64 data not shown #329

Open
csbun opened this issue Nov 4, 2015 · 5 comments
Open

image with base64 data not shown #329

csbun opened this issue Nov 4, 2015 · 5 comments

Comments

@csbun
Copy link

csbun commented Nov 4, 2015

I wrote an image with base64 like:

![](data:image/png;base64,...)

markdown-preview make it to html

<img src="/path/to/markdown/file/data:image/png;base64,...">

which we wish

<img src="data:image/png;base64,...">
@csbun
Copy link
Author

csbun commented Nov 5, 2015

I found one resolution is add these code in file lib/renderer.coffee after #88

continue if src.startsWith('data:image/')

@lee-dohm
Copy link
Contributor

lee-dohm commented Nov 6, 2015

In doing a little research on this, there is a security concern with just allowing any data:image scheme github/markup#270

If people want to test this, here's a full example:

![an example red dot](data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==)

@JamieMcDonnell
Copy link

anyone got this working yet? Or is it still a limitation on Git's side? Thanks.

@jhintringer
Copy link

There is a trick using the issue images in the readme.me.
http://solutionoptimist.com/2013/12/28/awesome-github-tricks/

Works for me like a charm :)

@pfarndt
Copy link

pfarndt commented Dec 13, 2017

Any progress here?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants