Skip to content

markmap/gatsby-remark-markmap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gatsby-remark-markmap

Visualize code blocks in Markdown files using markmap.

Demo

Input:

Render Markdown as mindmap:

```markdown markmap
# Food
## Fruits
- easy to eat
  - apple
  - banana
- not so easy
  - grapes
## Vegetables
- cabbage
- tomato
```

Output:

markmap

Installation

$ yarn add gatsby-remark-markmap

Usage

In your gatsby-config.js:

plugins: [
  {
    resolve: 'gatsby-transformer-remark',
    options: {
      plugins: [
        // Note that `gatsby-remark-markmap` must be put before other plugins
        // that handle code blocks, e.g. `gatsby-remark-prismjs`
        'gatsby-remark-markmap',
        'gatsby-remark-prismjs',
      ],
    },
  },
]

Options

  • options.markmap object

    JSON options for markmap rendering, see the documentation for more details.

  • options.assets (assets: IAssets) => IAssets

    Change the assets to preload for markmap. If provided, the returned assets will be preloaded.

Here is an example using options:

{
  resolve: 'gatsby-remark-markmap',
  options: {
    markmap: {/* markmap options */},
  },
},

Code

Code blocks with language of markdown and meta of markmap will be transformed into interactive markmaps.

```markdown markmap
# markmap
## contents
```

Related

About

Visualize code blocks in Markdown files using markmap.

Resources

Stars

Watchers

Forks

Packages

No packages published