From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yilkal Argaw Newsgroups: gmane.emacs.bugs Subject: bug#57131: regarding closing tags for non void html tags in html-mode skeletons Date: Fri, 12 Aug 2022 23:56:17 +0300 Message-ID: References: <87sfm1o5dz.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8503"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 57131@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Aug 12 22:57:11 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oMbiQ-00023Y-GO for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 12 Aug 2022 22:57:10 +0200 Original-Received: from localhost ([::1]:33548 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oMbiP-0000j3-7J for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 12 Aug 2022 16:57:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49150) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oMbiI-0000iu-IE for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 16:57:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:41047) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oMbiI-0005Ye-A2 for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 16:57:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oMbiI-0006OB-6W for bug-gnu-emacs@gnu.org; Fri, 12 Aug 2022 16:57:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Yilkal Argaw Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 12 Aug 2022 20:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57131 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: notabug Original-Received: via spool by 57131-submit@debbugs.gnu.org id=B57131.166033779524526 (code B ref 57131); Fri, 12 Aug 2022 20:57:02 +0000 Original-Received: (at 57131) by debbugs.gnu.org; 12 Aug 2022 20:56:35 +0000 Original-Received: from localhost ([127.0.0.1]:59028 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMbhr-0006NT-Et for submit@debbugs.gnu.org; Fri, 12 Aug 2022 16:56:35 -0400 Original-Received: from mail-yw1-f180.google.com ([209.85.128.180]:44648) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMbhp-0006N3-Ut for 57131@debbugs.gnu.org; Fri, 12 Aug 2022 16:56:34 -0400 Original-Received: by mail-yw1-f180.google.com with SMTP id 00721157ae682-31f661b3f89so20949027b3.11 for <57131@debbugs.gnu.org>; Fri, 12 Aug 2022 13:56:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=v2EWZgRTnsH77ZpVMFZ+qjzVGaphUeAQSuj5ZboZDw4=; b=WFmCpQY+fGkS4UkiUDGlXXqj1sswmMjJnxV6g+szJvCTLZr9W+kytipwghAoR1ajcL a487fMpp225Au+EvCJFY6cNC8z8kcHSGtzZW9QkzGL0J9xHjwSaS0hUx8T35exScDNdx EZTs/hiIfvLE1MABpGBTgiqeWDNf4ZoVkMbUlnuuLjWOhS6GCNxG4/Lre2/YYoxY+44K e4S18slFk2Rv5X+BujcDm5M6bzISD6Pio73GYbyYUIJXfu+nuQ3vcFLgQQhNSX+p7n2g thBDGZDawFc2iTLkSYzU/6aE/oEWZgcijw4dDbJyqSFde3Ned3KKl5eaZ1g01mMHzxz5 loBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=v2EWZgRTnsH77ZpVMFZ+qjzVGaphUeAQSuj5ZboZDw4=; b=TYYSc/V0gXodMUo8jXWJXMPT3tnuiWIix6viHIb7P4ugJuqCIkY/nhMZfr/jwMQLlf bxYsoF+K+30eKe79NomAaaqUAW0uonLS//wR+2xwgRFSBPevBduaAvDqiGj5EY5vDsun mxHdclwNDKWyXo66JFAPhFs3NHp9RFyuorZ7SItEK5OAYDKLtkzhitRTnqm84LaFrQC1 qDjv+wHVRqHEQSSLQTqFRUvvVJirqpqOtESvmtljslmfueZHf3EFvyKhNqXQX1bB1CRn 2Bhy3KmzVAnwcxSuagF5dImyKbfzzwhtkhwI8qceP7QmFhddS0W0c3ZaLadXeFH+VTGE Crag== X-Gm-Message-State: ACgBeo2Q+qbXYRW3Tctid+z1cxtwzcJbsbsxrhyhG9o7Z9VKgTc5i/S+ jrBLsBXxsrckndA72/sWTTWgBRu3aonRi43kbymD5TyYz3c= X-Google-Smtp-Source: AA6agR5zAGR6a9OoOekEHSALgLl2CNOlIVKcZixt5fU+oM993WCFPhbGUWc/FFcmLQKZuaahFrSkgfuShyNYGsL8RDM= X-Received: by 2002:a81:1615:0:b0:326:8d61:6259 with SMTP id 21-20020a811615000000b003268d616259mr5534293yww.164.1660337788358; Fri, 12 Aug 2022 13:56:28 -0700 (PDT) In-Reply-To: <87sfm1o5dz.fsf@gnus.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:239466 Archived-At: Hi > No, that's not the convention used in "modern html". Quite the opposite. Sorry if I am wrong. I will list the reasons for what I said. I am not trying to make this into a debate but I am listing them if they make my argument clearer. 1. The wording in the HTML5 standard optional tags section Reference Link: https://www.w3.org/TR/2018/SPSD-html5-20180327/syntax.html#optional-tags The wording used in this specification is that the aforementioned closing tags may be omitted. There is no enforcement or recommendation on this behavior. So a user is able to choose on the behavior that one requires and it would not make the code XML. So the editor should not limit this option for XML code only. Note: I am not talking about treating html and xml the same. I am also not referring to tags that are labeled as void-elements in the HTML5 standard but require closing tags on XML. I don't want to close tag for example but I might prefer to have closing tags for

  • and so on. So what I was referring to was having a variable like html-close-optional-tags or html-close-optional-tags-alist which will allow the user to specify this behavior instead of just saying go to use xml-mode if you need this behavior. 2. This is how other tools do it so I may not be only one who prefers to close my list-items and paragraphs. - Web Mode in Emacs - Emmet on Emacs - VS code - Cuda text - Atom (RIP) - Bluefish Editor - Sublime Text 3 - Vim (vim-closetag plugin) I have even looked into the html source of w3.org and the close their
  • ,

    and tags. With Regards Yilkal A. On Fri, Aug 12, 2022 at 6:20 PM Lars Ingebrigtsen wrote: > > Yilkal Argaw writes: > > > The problem with using them is that they would not > > generate closing tags for many of the tags (like

  • because it > > is assumed that only xml needs closing tags and the closing pairs are > > controlled by the variable sgml-xml-mode. There should be a variable > > to control this behaviour > > The variable that controls this is `sgml-xml-mode', so just set that to > a non-nil value if you prefer these functions to insert close tags. > > > because the convention used widely in modern > > html is to close tags as long as they are not "void elements". > > No, that's not the convention used in "modern html". Quite the opposite. > > > This behaviour is even assumed in the indentation behaviour that it > > causes weird indentation when inserting the something like list items > > inside unordered list. > > If something is doing that, then it's not parsing HTML properly. HTML > isn't XHTML. > > I don't see anything to fix here, so I'm closing this bug report.