remcohaszing / rehype-mermaid

A rehype plugin to render mermaid diagrams
MIT License
68 stars 8 forks source link

I get an error that repeatedly asks me to install Playwright. #18

Closed kght6123 closed 4 months ago

kght6123 commented 4 months ago

Even if I run npx playwright install as instructed or npx playwright install --with-deps chromium mentioned in the README, the error persists.

node:internal/process/promises:289
            triggerUncaughtException(err, true /* fromPromise */);
            ^

browserType.launch: Executable doesn't exist at /Users/kght6123/Library/Caches/ms-playwright/chromium-1097/chrome-mac/Chromium.app/Contents/MacOS/Chromium
╔═════════════════════════════════════════════════════════════════════════╗
║ Looks like Playwright Test or Playwright was just installed or updated. ║
║ Please run the following command to download new browsers:              ║
║                                                                         ║
║     npx playwright install                                              ║
║                                                                         ║
║ <3 Playwright Team                                                      ║
╚═════════════════════════════════════════════════════════════════════════╝

Since the problem was solved with the content described in the issue of mermaid-isomorphic, I think that the README of rehype-mermaid should also be rewritten to the following command.

npx playwright-core install --with-deps chromium

https://github.com/remcohaszing/mermaid-isomorphic/issues/4 https://github.com/remcohaszing/mermaid-isomorphic/commit/fee3629efd4dc2ea1c599f0fd82b620c1896983c

remcohaszing commented 4 months ago

You’re absolutely correct! Would you like to send a PR?

kght6123 commented 4 months ago

@remcohaszing I created a pull request. #19