New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Markdown Table doesn't support CJK characters #1534
Comments
Hi @avasconcelos114, Thanks for the report. Are you able to post the original message as it appears when typed in the textbox or when you edit the post? I tried recreating what you typed, and it's working fine for me. I'm on iOS, but that shouldn't matter for this.
|
My apologies. I tested all these including the one I sent originally on a Nexus 5, and it does appear to work differently on Android than iOS. I really did not expect that. I've filed a ticket to track this on our end (link) |
All good :) Also, I've been looking through the markdown parser and I think I got an approximate idea about what may be going wrong (although I still don't understand why, and especially why only on Android... ) The first thing I noticed, is that the container types on every row after the first one becomes a When checking why that was the case, I noticed that what happened was that
and in the end it seemed that when the header row is being parsed, the following condition somehow isn't being fulfilled:
And removing removing the
The remaining question is why is the condition not being fulfilled and causing the remaining nodes to be added as Either way, I'm sure the workaround I found is bound to be problematic, but I'm hoping that this information will help you find a more adequate solution :) Edit: Creating an array from
Bonus: Found an issue that seems to be related to what's happening here |
Wow, nice work. The behaviour they describe in that ticket is bizarre, but I think that makes sense. I'll take a look at implementing it since I think we might do a 1.7.1 to fix that. That thread also mention it should be fixed by upgrading React Native which we're currently doing for 1.8, but we probably wouldn't want to do that big of an upgrade for a dot release |
Ah great! Just tested it again with your newest commit and it's working nicely :) Thank you for taking care of it |
Awesome, glad to hear it works. If you're using the version from the App Store or Play Store, it'll be fixed shortly in 1.7.1 |
Summary
When parsing a markdown table that includes a Chinese, Japanese, or Korean character, the table doesn't render.
Environment Information
Steps to reproduce
Expected behavior
Should render the markdown table with CJK characters included
Observed behavior
Only the header renders, but the original text is seen below
Note: above issue happened when the Korean characters "버스" were added to the second row of the table, the same happened when testing when adding random Chinese or Japanese characters. It otherwise renders fine when the whole table only uses the alphabet
Possible fixes
I'm unfamiliar with how markdown parsing works, but running
console.log
on this function revealed that the rows containing CJK characters weren't even logged.The text was updated successfully, but these errors were encountered: