Naughty Program Manipulator

    gatsby-remark-markmap

    0.4.1 • Public • Published

    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

      Defaults as {}.

      Passed to markmap-view.

    • 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

    Install

    npm i gatsby-remark-markmap

    DownloadsWeekly Downloads

    28

    Version

    0.4.1

    License

    MIT

    Unpacked Size

    5.94 kB

    Total Files

    6

    Last publish

    Collaborators

    • gera2ld