diff --git a/docs/Tutorials.md b/docs/Tutorials.md index 089ba34ab..909d4f435 100644 --- a/docs/Tutorials.md +++ b/docs/Tutorials.md @@ -39,8 +39,9 @@ This is also working with colab and jupyter lab notebooks. ```python import base64 - -graphbytes = graph.encode("ascii") +import requests, io +from PIL import Image +import matplotlib.pyplot as plt graph = """ graph LR; @@ -51,16 +52,13 @@ graph LR; E--> B & C & D; """ +graphbytes = graph.encode("ascii") base64_bytes = base64.b64encode(graphbytes) base64_string = base64_bytes.decode("ascii") - -import requests, io -from PIL import Image -import matplotlib.pyplot as plt - img = Image.open(io.BytesIO(requests.get('https://mermaid.ink/img/' + base64_string).content)) plt.imshow(img) ``` + **Output** ![image](img/python-mermaid-integration.png) diff --git a/docs/n00b-overview.md b/docs/n00b-overview.md index 1c2ee9f05..556e071ba 100644 --- a/docs/n00b-overview.md +++ b/docs/n00b-overview.md @@ -63,7 +63,7 @@ Being based on markdown, mermaid can be used, not only by accomplished front-end In fact one can pick up the syntax for it quite easily from the examples given and there are many tutorials in the internet. ## Mermaid is for everyone. -Video [Tutorials](./getting-started/Tutorials.md) are also available for the mermaid [live editor](https://mermaid-js.github.io/mermaid-live-editor/). +Video [Tutorials](https://mermaid-js.github.io/mermaid/#/./Tutorials) are also available for the mermaid [live editor](https://mermaid-js.github.io/mermaid-live-editor/). For information on how to use mermaid, click [here](https://mermaid-js.github.io/mermaid/#/n00b-gettingStarted). Alternatively, you could also view the [integrations and uses](https://mermaid-js.github.io/mermaid/#/./integrations), to see how mermaid is used.