Skip to content
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

Multiline strings #29

Open
icanzilb opened this issue Sep 7, 2022 · 3 comments
Open

Multiline strings #29

icanzilb opened this issue Sep 7, 2022 · 3 comments
Labels
bug Something isn't working

Comments

@icanzilb
Copy link
Collaborator

icanzilb commented Sep 7, 2022

I see that swift-markdown is getting confused by multiline strings. Maybe a good idea is to encode newlines as \n?

@icanzilb icanzilb added the bug Something isn't working label Sep 7, 2022
@DivineDominion
Copy link
Contributor

Can you elaborate? Is it the """...""" notation?

@icanzilb
Copy link
Collaborator Author

icanzilb commented Sep 9, 2022

Oh no, you are right — this issue is very vague (I was doing other stuff and got sloppy, my bad).

Multiline strings in markdown tables seem to trip swift-markdown when parsing the text. I didn't dive deep to debug what exactly is happening but trying to (simply) continue the text on the next line doesn't seem to work. Using a "\n" in the text also didn't seem to be on the right side of swift-markdown.

@DivineDominion
Copy link
Contributor

DivineDominion commented Sep 9, 2022

Ah, cell contents you mean -- yeah, multiline cells aren't possible in any Markdown table implementation I tried.

You basically would need to custom encode/decode string cells IIRC to replace a line break character or character sequence. (In TableFlip I santiize user input by replacing line breaks with single spaces, for example.)

Markdown is the wrong format for this purpose, even though HTML can deal with complex cells just fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants