pavittarx / editorjs-html

A javascript library to parse editorjs clean data to html. It is adaptable and usable in all kind of projects.
https://runkit.com/pavittarx/editorjs-html-example
MIT License
331 stars 61 forks source link

Image doesn't work #16

Closed akisantos closed 3 years ago

akisantos commented 3 years ago

image

pavittarx commented 3 years ago

@akisantos can your provide me with some copy of your generated data, specifically the blocks with the issue.

akisantos commented 3 years ago

@akisantos can your provide me with some copy of your generated data, specifically the blocks with the issue. @pavittarx I edit codes myself and it's work. Here is code i changed: image:function(t){var e=t.data,url=e.url,n=e.caption?e.caption:"Image";;return'<img src="'+(url)+'" alt="'+n+'" />'}.

pavittarx commented 3 years ago

@akisantos If you feel issues with the default parser functions, or if they don't work the way you want them to. You can always override them with your own. Overrides are written in the same way you would write a function for a custom block.

However, I'll see to this and fix this over here itself.

akisantos commented 3 years ago

@pavittarx cool, keep it up. Thank you very much!