1

The current behavior of org-md-export-to-markdown is to export Org Mode tables as HTML tables. I would like tables to be exported as Markdown tables (as explained here).

1

Use the ox-gfm package

The gfm part in the package name stands for "Github Flavored Markdown".

This package is available at MELPA. The source code can be found at this repository at Github. A minimal working example is shown below.

Consider the following Org Mode file

* The first heading

| word    | number |
|---------+--------|
| one     |      1 |
| ten     |     10 |
| hundred |    100 |

* The second heading

#+begin_src bash
echo "Hello World"
#+end_src

#+RESULTS:
#+begin_example
Hello World
#+end_example

By using org-gfm-export-as-markdown (function defined in the ox-gfm package) in the Org Mode buffer, the newly created buffer would look like

# The first heading

| word    | number |
|------- |------ |
| one     | 1      |
| ten     | 10     |
| hundred | 100    |


# The second heading

```bash
echo "Hello World"
```

```
Hello World
```

System information

emacs --version
GNU Emacs 27.2
Copyright (C) 2021 Free Software Foundation, Inc.
GNU Emacs comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of GNU Emacs
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.
(org-version)
9.4.4

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.