Skip to content

Conversation

@hectorcrispens
Copy link

Hello, I hope you are fine.
I installed diagram plugin but I got error with pupperteer and chrome-headless-shell version. I could resolve modify the plugin including an option to set pupperteer directory.
I Share with you my config plugin file:

return {
  {
    "hectorcrispens/diagram.nvim",
    dependencies = {
      "3rd/image.nvim",
    },
    opts = { -- you can just pass {}, defaults below
      renderer_options = {
        mermaid = {
          background = "transparent", -- nil | "transparent" | "white" | "#hex"
          theme = "dark", -- nil | "default" | "dark" | "forest" | "neutral"
          scale = 1, -- nil | 1 (default) | 2  | 3 | ...
          width = nil, -- nil | 800 | 400 | ...
          height = nil, -- nil | 600 | 300 | ...
          pupperteer = "/home/hector/.config/pupperteer/puppeteer.config.json",
        },
        plantuml = {
          charset = nil,
        },
        d2 = {
          theme_id = nil,
          dark_theme_id = nil,
          scale = nil,
          layout = nil,
          sketch = nil,
        },
        gnuplot = {
          size = nil, -- nil | "800,600" | ...
          font = nil, -- nil | "Arial,12" | ...
          theme = nil, -- nil | "light" | "dark" | custom theme string
        },
      },
    },
  },
}

and pupperter.config.json

{
  "executablePath": "/home/hector/.cache/puppeteer/chrome-headless-shell/linux-132.0.6834.110/chrome-headless-shell-linux64/chrome-headless-shell",
  "puppeteer": {
    "chromiumRevision": "132.0.6834.110"
  }
}

I hope this request is useful to improve your plugin.

@3rd
Copy link
Owner

3rd commented Feb 1, 2025

Hey, this is great thank you, can you rename it from pupperteer to puppeteer_path:?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants