Comments (3)
Hi!
This seems to work fine with mdformat-tables:
foo@bar:~$ python3 -m venv venv
foo@bar:~$ source venv/bin/activate
(venv) foo@bar:~$ pip install mdformat mdformat-tables
Collecting mdformat
Using cached mdformat-0.7.16-py3-none-any.whl (29 kB)
Collecting mdformat-tables
Using cached mdformat_tables-0.4.1-py3-none-any.whl (4.6 kB)
Collecting markdown-it-py<3.0.0,>=1.0.0
Using cached markdown_it_py-2.2.0-py3-none-any.whl (84 kB)
Collecting tomli>=1.1.0
Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting mdurl~=0.1
Using cached mdurl-0.1.2-py3-none-any.whl (10.0 kB)
Installing collected packages: tomli, mdurl, markdown-it-py, mdformat, mdformat-tables
Successfully installed markdown-it-py-2.2.0 mdformat-0.7.16 mdformat-tables-0.4.1 mdurl-0.1.2 tomli-2.0.1
(venv) foo@bar:~$ mdformat --version
mdformat 0.7.16 (mdformat_tables: 0.4.1)
(venv) foo@bar:~$ printf '| variable | type |\n| --- | --- |\n| ids | List \| Tuple |\n' | mdformat -
| variable | type |
| -------- | ------------- |
| ids | List \| Tuple |
The table syntax is not CommonMark so you'll need the table plugin. See https://mdformat.readthedocs.io/en/stable/users/plugins.html#parser-extension-plugins
from mdformat.
Thanks for opening your first issue here! Engagement like this is essential for open source projects! 🤗
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! 🎉
from mdformat.
Hi!
...
The table syntax is not CommonMark so you'll need the table plugin. See https://mdformat.readthedocs.io/en/stable/users/plugins.html#parser-extension-plugins表格语法不是 CommonMark,因此您需要表格插件。见 https://mdformat.readthedocs.io/en/stable/users/plugins.html#parser-extension-plugins
Thanks!
Now I see. I need to explicitly enable the tables
extension! I added the parameter extensions={"tables"}
to mdformat.text
, and it worked.
from mdformat.
Related Issues (20)
- Not Working In Python 3.11? HOT 5
- Error: Could not format HOT 2
- Alt text wrapped in grave marks is deleted HOT 2
- Formatted md renders different html than original md HOT 2
- image path is falsely patched with `<>` if URL includes `()`, breaks render HOT 5
- Double slash in math formular HOT 3
- Incorrecly reformats python code HOT 1
- convert inline links to references? HOT 2
- Support json schema
- Word-wrap on sentence (punctuation) and width. HOT 1
- Inline elements in image descriptions are flattened and stripped HOT 2
- Numbers in ordererd lists are ignored when using MDRenderer/MDFormat HOT 3
- Feature request: Respect .gitignore'd files HOT 1
- Checkbox convert HOT 2
- Options to disable/enable rules HOT 3
- Option to specify path to configuration file HOT 1
- Support plugin options in the configuration file HOT 1
- Format output as filename:lineno: message
- Non standard output between core and plugins?
- On/off comments
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mdformat.