From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/33232 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Fritz Fritzy Newsgroups: gmane.text.pandoc Subject: Re: Markdown: simple syntax for arbitrary nesting Date: Wed, 25 Oct 2023 23:36:37 -0700 (PDT) Message-ID: <80b20bbf-1f3f-4473-9d0d-5017ce7a1baen@googlegroups.com> References: <5573f042-48a4-4115-8b1d-a86c13eb319an@googlegroups.com> <297BE1CF-4874-44E3-B6AA-9B9B87378A6B@gmail.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_846_1798360636.1698302197834" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3995"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBDOITKNXR4IRB54R5CUQMGQESKUNHAQ-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Thu Oct 26 08:36:43 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-oa1-f59.google.com ([209.85.160.59]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1qvtz0-0000pi-Ep for gtp-pandoc-discuss@m.gmane-mx.org; Thu, 26 Oct 2023 08:36:42 +0200 Original-Received: by mail-oa1-f59.google.com with SMTP id 586e51a60fabf-1ef5310a497sf373167fac.1 for ; Wed, 25 Oct 2023 23:36:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1698302201; x=1698907001; darn=m.gmane-mx.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :sender:from:to:cc:subject:date:message-id:reply-to; bh=4lh+ibyLNFCfEPHyKz1F4QP6esjmy7705h0lR+p3Wkk=; b=iAJe+Gly3CHhw8XbxCHgSaAh7xzHYdOzlABRzHZZe+HAougoU47DACMb74f1veGtML /nKKjeSiOc7VHLCAIZYN2sauvduZmfvLfn5gnRJ7MPfoaS0mwXLlfLIObxIYWlENFZwS BqQsLQwuWkUXvewJjf5sKuOJIGNNpPearphV5/xmQnEn6p5MIWJz0+xJqqG600T7U7yg phphl+jXNSQZk7p5hbumBfn3V/xZXjmC26HCCNep6H9LCBmg4cAQr68nb10K+Bfa1UO9 OZ1D44flIvAPe+WgpSIvUlwpkxUVQspsa0YG87lWy02UKF/E7+HAjGYbCygsr+FTaTVX VTwA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698302201; x=1698907001; darn=m.gmane-mx.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=4lh+ibyLNFCfEPHyKz1F4QP6esjmy7705h0lR+p3Wkk=; b=JlvmYnEPmJe6NBuiKIaypD/ZtGxVAzP2WOYQNdCH4crmd81i0S76IvtheXu/YSrKlJ wARCvVO8fpg9y7Jo6cYdIDxW5V3/iD9vbSXZ8auFhDw0D3R3rz0HvAc/DikVNCQhdv0I 8A84KsBR6UOoy5yZR4w35haUITUyTATwMjV/93YrgfUEzMJQ0L1jwsmz9tcPMLgvKVSU k0PSTWmgOyqj0xxKjbIWg8hwcCzqPF4C1+VF8I0NdoaRU9OMW6HhXkyoCK75Pjdqzgv4 AudsBODCceFc2l7vqbokgIizxsHZAlnX32WONOzLztOgRLE08fbLyPbLusAEP+1KAf6m eePg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698302201; x=1698907001; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-beenthere:x-gm-message-state:sender:from :to:cc:subject:date:message-id:reply-to; bh=4lh+ibyLNFCfEPHyKz1F4QP6esjmy7705h0lR+p3Wkk=; b=oOCkqK2dVoPf+tU7iLSb42xHNf72qC6wZTfztQSUhFNB51OjAnhHNXWBYiOsKA4vdl NsIdIzUwBssp9Tt8ePbBxqgKcxEO804xFSBFVEZrF80GsGnCiLzZGLL1k78KktgH9WfR upZbrtgDacAvSyDcylULM/0qVcZaASWp+rn1nw3omtWRhzAosYY3qOWcxeJUcVkqW9mD H0ITvGOOVD8T7yEHhVt1IQYlBSmGr3KoyTX+RI7PAL1YX+wAWVhOSJEGHCV0W+bVTrak JS/r+MeJDxiEvvXqcs28oecsxQ3Vyip82P3VHId2epSUsgm4dK Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOJu0YzVYdIdIf7U2CBrJ8ALQDRu9JFfn8PyFJ+61zRBMtnoynd55GXc KjH4ACFqZsHwa+qKmZBQxCA= X-Google-Smtp-Source: AGHT+IHnEEsc8WCSkZMtD5NKXEKTMMH8sczusfH0fU3JHzXzUbAu0SH4DTGePH3J2g99/GYos6OwiA== X-Received: by 2002:a05:6870:b8f:b0:1ea:50ec:7087 with SMTP id lg15-20020a0568700b8f00b001ea50ec7087mr22283421oab.26.1698302201347; Wed, 25 Oct 2023 23:36:41 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6870:9b0b:b0:1e9:9551:4f75 with SMTP id hq11-20020a0568709b0b00b001e995514f75ls325042oab.2.-pod-prod-05-us; Wed, 25 Oct 2023 23:36:38 -0700 (PDT) X-Received: by 2002:a05:6808:1a1e:b0:3a7:b55e:a54 with SMTP id bk30-20020a0568081a1e00b003a7b55e0a54mr6349639oib.1.1698302198608; Wed, 25 Oct 2023 23:36:38 -0700 (PDT) In-Reply-To: <297BE1CF-4874-44E3-B6AA-9B9B87378A6B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> X-Original-Sender: Emile.Valjean-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:33232 Archived-At: ------=_Part_846_1798360636.1698302197834 Content-Type: multipart/alternative; boundary="----=_Part_847_1353527789.1698302197834" ------=_Part_847_1353527789.1698302197834 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks for the answer! RE nesting:=20 I mean things like the use of asterisk inside emphasis/bold spans, or the= =20 different ways paragraphs/lists/quotes/pre blocks work together wrt=20 indentation and newlines. I understand that when one knows the parsing rules, it's probably always=20 doable to make them do what one wants, but personally I often get them=20 wrong. RE markdown's design:=20 As far as I can tell, markdown has grown way farther than those initial=20 goals, and is now used for more than simple email-like content. Looking at all the different extensions defined and e.g. provided by=20 pandoc, I believ that ease of readability has been already left out: one=20 has to know the semantics of footnotes, custom spans, custom divs,=20 attribute blocks already to know how to read them. Obviously, adding yet another new syntax construct can be seen as just=20 adding to the already present overhead, but it seems to me like: 1. It's easy to reason about, in that nesting is natural to understand,= =20 and its parsing rules being (close to?) context free makes figuring out = how=20 to make it work easier. 2. It would be enough to replace/cover quite a few of the already=20 present constructs (e.g. all the divs and spans, and maybe also attribut= e=20 blocks for titles?), thus reducing the cognitive cost both for writing a= nd=20 reading markdown. 3. On a similar note, it would mean that e.g. when writing things like= =20 1. emphasized text containing asterisks, one could just start with=20 *{}*, and not have to fear that the emphasis gets dropped. 2. any kind of block, say a list item, or a quote block, one could=20 use braces again to reset the indentation to any value we like. =20 In short, it seems to me that it's a simple enough, orthogonal and rather= =20 powerful syntax that doesn't _have_ to be used, but makes writing complex= =20 documents that much easier. I understand that you and many people have probably spent way more time=20 thinking about this than I have, and won't try to push my point further if= =20 it hasn't been in any way convincing so far :) Thanks for your time, and for pandoc, which has already proven incredibly= =20 useful to me! On Wednesday, October 25, 2023 at 2:58:32=E2=80=AFPM UTC John MacFarlane wr= ote: > > > > On Oct 24, 2023, at 11:06 PM, Fritz Fritzy wrote: > >=20 > > Hi, > >=20 > > Using markdown, I've often been frustrated by > >=20 > > =E2=80=A2 Its flat/non-recursive/non-nested nature, by which I mean tha= t you=20 > mostly cannot write "arbitrary" markdown inside most elements, and if you= =20 > can, you have to be very careful with whitespaces/indentation/etc. > > > I'm not sure what you mean: generally you can nest things, you just have= =20 > to pay attention to the syntax. Examples? > > > > =E2=80=A2 The impossibility to easily interlink to arbitrary parts of t= he=20 > document. > > To solve both issues, I'd like to propose an extension that allows=20 > "simply" using braces (or some other punctuation pair) to allow nesting,= =20 > with an option to tag/add attributes to the contents like that. > > > I think this goes against the spirit of Markdown, which prioritizes sourc= e=20 > readability rather than easy writeability. > > "The overriding design goal for Markdown=E2=80=99s formatting syntax is t= o make it=20 > as readable as possible. The idea is that a Markdown- formatted document= =20 > should be publishable as-is, as plain text, without looking like it=E2=80= =99s been=20 > marked up with tags or formatting instructions." ( > http://daringfireball.net/projects/markdown/) > > > --=20 You received this message because you are subscribed to the Google Groups "= pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/80b20bbf-1f3f-4473-9d0d-5017ce7a1baen%40googlegroups.com. ------=_Part_847_1353527789.1698302197834 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks for the answer!

RE nesting:
I mean things like the use of asterisk inside emphasis/bold spans,= or the different ways paragraphs/lists/quotes/pre blocks work together wrt= indentation and newlines.
I understand that when one knows the p= arsing rules, it's probably always doable to make them do what one wants, b= ut personally I often get them wrong.

RE m= arkdown's design:
As far as I can tell, markdown has grown= way farther than those initial goals, and is now used for more than simple= email-like content.
Looking at all the different extensions defi= ned and e.g. provided by pandoc, I believ that ease of readability has been= already left out: one has to know the semantics of footnotes, custom spans= , custom divs, attribute blocks already to know how to read them.
Obviously, adding yet another new syntax construct can be seen as just add= ing to the already present overhead, but it seems to me like:
  • It's easy to reason about, in that nesting is natural to understand, a= nd its parsing rules being (close to?) context free makes figuring out how = to make it work easier.
  • It would be enough to replace/cover quite a= few of the already present constructs (e.g. all the divs and spans, and ma= ybe also attribute blocks for titles?), thus reducing the cognitive cost bo= th for writing and reading markdown.
  • On a similar note, it would me= an that e.g. when writing things like=C2=A0
    1. emphasized text containi= ng asterisks, one could just start with *{}*, and not have to fear that the= emphasis gets dropped.
    2. any kind of block, say a list item, or a qu= ote block, one could use braces again to reset the indentation to any value= we like.
  • In short, it seems to me that= it's a simple enough, orthogonal and rather powerful syntax that doesn't _= have_ to be used, but makes writing complex documents that much easier.

    I understand that you and many people have probably= spent way more time thinking about this than I have, and won't try to push= my point further if it hasn't been in any way convincing so far :)

    Thanks for your time, and for pandoc, which has already= proven incredibly useful to me!

    On Wednesday, October 2= 5, 2023 at 2:58:32=E2=80=AFPM UTC John MacFarlane wrote:


    > On Oct 24, 2023, at 11:06 PM, Fritz Fritzy <emile....-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
    >=20
    > Hi,
    >=20
    > Using markdown, I've often been frustrated by
    >=20
    > =E2=80=A2 Its flat/non-recursive/non-nested nature, by which I me= an that you mostly cannot write "arbitrary" markdown inside most = elements, and if you can, you have to be very careful with whitespaces/inde= ntation/etc.


    I'm not sure what you mean: generally you can nest things, you just= have to pay attention to the syntax. Examples?


    > =E2=80=A2 The impossibility to easily interlink to arbitrary part= s of the document.
    > To solve both issues, I'd like to propose an extension that al= lows "simply" using braces (or some other punctuation pair) to al= low nesting, with an option to tag/add attributes to the contents like that= .


    I think this goes against the spirit of Markdown, which prioritizes sou= rce readability rather than easy writeability.

    "The overriding design goal for Markdown=E2=80=99s formatting synt= ax is to make it as readable as possible. The idea is that a Markdown- form= atted document should be publishable as-is, as plain text, without looking = like it=E2=80=99s been marked up with tags or formatting instructions."= ; (http:= //daringfireball.net/projects/markdown/)


    --
    You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
    To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
    To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/80b20bbf-1f3f-4473-9d0d-5017ce7a1baen%40googlegroups.= com.
    ------=_Part_847_1353527789.1698302197834-- ------=_Part_846_1798360636.1698302197834--