Star on GitHub
function helps you to dump json.
md-to-jsonify also provides a function to convert a Markdown table to JSON. Here's how you can use it:
md-to-jsonify
import { extract } from 'md-to-jsonify'; const markdownTable = ` | Name | Age | Website | |-------|-----|------------------------| | John | 25 | [Example Website 1](https://example.com) | | Alice | 30 | [Example Website 2](https://example.org) | `; const jsonData = extract(markdownTable); console.log(jsonData);Copy to clipboard
import { extract } from 'md-to-jsonify'; const markdownTable = ` | Name | Age | Website | |-------|-----|------------------------| | John | 25 | [Example Website 1](https://example.com) | | Alice | 30 | [Example Website 2](https://example.org) | `; const jsonData = extract(markdownTable); console.log(jsonData);
[ { "Name": "John", "Age": "25", "Website": "https://example.com" }, { "Name": "Alice", "Age": "30", "Website": "https://example.org" } ]Copy to clipboard
[ { "Name": "John", "Age": "25", "Website": "https://example.com" }, { "Name": "Alice", "Age": "30", "Website": "https://example.org" } ]