nips icon indicating copy to clipboard operation
nips copied to clipboard

NIP-01 text_note content clarification

Open macterra opened this issue 2 years ago • 5 comments

NIP-01 states:

1: text_note: the content is set to the text content of a note (anything the user wants to say). Non-plaintext notes should instead use kind 1000-10000 as described in NIP-16.

Does markdown count as plaintext for text_notes? Clarification needed.

macterra avatar Feb 24 '23 15:02 macterra

I don't believe so. Markdown makes more sense in NIP-23: https://github.com/nostr-protocol/nips/blob/master/23.md

Marcelo-Theodoro avatar Feb 24 '23 15:02 Marcelo-Theodoro

I understand NIP-23 suggests markdown for the content, but NIP-01 does not prohibit markdown for notes. This should be clarified in NIP-01.

macterra avatar Feb 24 '23 15:02 macterra

Don't you think that this part is enough:

1: text_note: the content is set to the text content of a note (anything the user wants to say). Non-plaintext notes should instead use kind 1000-10000 as described in NIP-16.

I consider markdown as "non-plaintext"

Marcelo-Theodoro avatar Feb 24 '23 16:02 Marcelo-Theodoro

Does everyone consider markdown as "non-plaintext"? If not, we might need some clarification here.

macterra avatar Feb 24 '23 16:02 macterra

The consensus from a while back was that markdown is fine insofar as it is also plaintext. So lists/headings are fine, but markdown links (for example) are not. For clients that want to render this subset, thats fine, but don't encourage your users to spam other clients with code.

staab avatar Feb 24 '23 17:02 staab

The consensus from a while back was that markdown is fine insofar as it is also plaintext.

Do you have a link to that discussion?

macterra avatar Feb 24 '23 19:02 macterra

Markdown appears to be on the roadmap for https://iris.to/

macterra avatar Feb 24 '23 19:02 macterra

Relevant https://github.com/jonathanleger/nostrgram/issues/1

Marcelo-Theodoro avatar Feb 24 '23 21:02 Marcelo-Theodoro

I don't, somewhere in telegram probably. That was @fiatjaf's opinion iirc, and I agree.

Edit: ah, I see he's still at it!

staab avatar Feb 24 '23 21:02 staab

Relevant jonathanleger/nostrgram#1

In that case, I think NIP-01 needs clarification because one of the main selling points of markdown is that it is a plaintext format.

macterra avatar Feb 25 '23 15:02 macterra

Please don't do Markdown.

fiatjaf avatar Feb 25 '23 16:02 fiatjaf

379252f992c2528e287bc4ce7faee5631aa3f73c

fiatjaf avatar Feb 25 '23 16:02 fiatjaf

Please ask Martti to not do Markdown -- or, if he really wants to, ask him to disable the link syntax as in the issue linked above.

fiatjaf avatar Feb 25 '23 16:02 fiatjaf

Please ask Martti to not do Markdown -- or, if he really wants to, ask him to disable the link syntax as in the issue linked above.

Will do

macterra avatar Feb 25 '23 18:02 macterra