shurcooL-legacy / atom-markdown-format

Formats your Markdown text on save.

Home Page:https://atom.io/packages/markdown-format

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Configuration of how to format headlines

M-Fabian opened this issue · comments

First of all, I love this plugin as it makes all my documents much nicer. This said, I am not so happy with some decisions the plugin makes, and I wonder if it is possible to add some options about how to format the document.

One thing that annoys me particularly is that the plugin converts headlines with # or ## into underlined headlines (==== or ----). I dislike this for three reasons:

  • I prefer #-headlines throughout, because I often have three levels of headlines.
  • The plugin markdown-toc expects #-headlines.
  • Underlined headlines are not color-coded.

Since I expect that you have good reasons in favor of underlined headlines, I would love to have the option to disable reformatting of # and ## headlines.

Hi @M-Fabian,

Unfortunately, this Atom plugin has been deprecated, see https://github.com/shurcooL-legacy/atom-markdown-format#deprecation-notice. You can learn the reasons why in #26 if you wish.

About the change you're requesting, two comments:

  1. I wanted markdownfmt, which this Atom plugin is a wrapper around, to be configuration-free. It tries to make the best decisions and you need to accept them. The downside is that some decisions may not be most ideal, but the upside is that everyone using it will have consistent-looking and compatible Markdown style. However, because Markdown doesn't have a spec and people want many different features, this is quite hard.

  2. About using underlines instead of # and ##, I made that (difficult) decision a long time ago for 2 reasons, having markdownfmt made it easi(er) to align the headers automatically. The advantage of using ### notation is that it's easier to write by hand, but that doesn't apply here.

    Other than that, I think they're similar, but having the large === or --- separators really makes h1 and h2 stand out, which isn't bad IMO.

    You said you only use 3 levels of headlines and you prefer ### style. Have you considered using h3, h4 and h5? I.e., ###, #### and #####.

I'll close this because this is an unsupported plugin, but I don't mind answering followup comments. Just understand I can't make changes to the Atom plugin since it's deprecated.