Coder Social home page Coder Social logo

Comments (3)

bgschiller avatar bgschiller commented on August 30, 2024 4

I have a fork (described in #10) that includes an imageDir plugin option, but it's relative to each file's location. Would that work for you, or would you expect such an option to be relative to the package root?

It doesn't matter either way to me, so I'm happy to change it. Much easier to change it before it's merged though.

from remark-mermaid.

nonprofittechy avatar nonprofittechy commented on August 30, 2024 3

I think relative to the package root would work best here. At least for docusaurus, it expects all images to be in the /static/img directory, but you are allowed to put documents in subdirectories.

from remark-mermaid.

ambroiseRabier avatar ambroiseRabier commented on August 30, 2024

Any update on this issue ? I would love to use mermaid with docusaurus.

I don't know how you figured out, that the problem is with the file save location, all I get is:

Compiled with problems:

ERROR in ./docs/temp/mermaid test.md

Module build failed (from ./node_modules/@docusaurus/mdx-loader/lib/index.js):
SyntaxError: L:\PROJECTS_3\WEB\teaching-support-website\docs\temp\mermaid test.md: Unexpected token (18:2)

  16 | export default function MDXContent({
  17 |   components,
> 18 |   ...props
     |   ^
  19 | }) {
  20 |   return <MDXLayout {...layoutProps} {...props} components={components} mdxType="MDXLayout">
  21 |     <svg {...{
    at instantiate (L:\PROJECTS_3\WEB\teaching-support-website\node_modules\@babel\parser\lib\index.js:72:32)

Edit: Seem like some stuff going on there: https://docusaurus.io/feature-requests/p/add-mermaid-support
Edit2: I guess the issue is somewhat resolved with https://github.com/sjwall/mdx-mermaid ?

from remark-mermaid.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.