juiceo / react-native-easy-markdown

Simple & customizable React Native component to render Github-flavoured markdown using minimal native components.
https://www.npmjs.com/package/react-native-easy-markdown
65 stars 62 forks source link

Fix text wrapping, links #23

Closed zivester closed 4 years ago

zivester commented 5 years ago

Been working with this library for a couple weeks, and needed to fix a couple regressions that appeared in 1.2.0.

This brings back Utils.isTextOnly which was needed to get proper inline text wrapping. 1.20.0 had a regression where text only blocks, e.g.:

This is a text block **with bold** items that would wrap to three lines

Would render like:

This is a text block with bold items that would wrap to three lines

It now properly checks when rendering certain components, and if all children are of type Text, our wrapper should also be text.

I also removed the need for static class properties as it unnecessarily requires build tools that should not be required. I have a babel build version of this module, and plan on doing a rewrite in the future with typescript if there is any interest from the maintainer and/or community.

I believe this should fix #15, fix #18, fix #20

juiceo commented 5 years ago

Hey, thanks for the PR and apologies for my inactivity. Currently I personally have no use for this library so responding to these has been duly slow.

I would fully support you doing a rewrite of the library, and can happily transfer the npm package ownership to you. Hit me up via email at juuso.u.lappalainen@gmail.com if you're interested in taking over :)

zivester commented 5 years ago

Sounds great @lappalj4, just sent you an email.

zivester commented 5 years ago

I've released these fixes on the new app version which we now maintain v1.3.0 at https://github.com/TitanInvest/react-native-easy-markdown

Also installable with npm under this same package name.