This website works better with JavaScript.
Home
Help
Sign In
heuzef
/
diagrams
mirror of
https://github.com/mingrammer/diagrams.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Releases
43
Wiki
Activity
Browse Source
feat: support inline rendering for jupyter notebook
tags/v0.6.3
mingrammer
4 years ago
parent
07ffe71bce
commit
547eefd55b
1 changed files
with
3 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+3
-0
diagrams/__init__.py
+ 3
- 0
diagrams/__init__.py
View File
@@ -139,6 +139,9 @@ class Diagram:
os.remove(self.filename)
setdiagram(None)
def _repr_png_(self):
return self.dot.pipe(format='png')
def _validate_direction(self, direction: str) -> bool:
direction = direction.upper()
for v in self.__directions:
Write
Preview
Loading…
Cancel
Save