Cells: Diagrams
Diagrams used in Cells are created with draw.io.
Edit existing diagrams
Load the .drawio.png
or .drawio.svg
file directly into draw.io, which you can use in several ways:
- Best: Use the draw.io integration in VS Code.
- Good: Install on MacOS with
brew install drawio
or download the draw.io desktop. - Good: Install on Linux by downloading the draw.io desktop.
- Discouraged: Use the draw.io website to load and save files.
Create a diagram
To create a diagram from a file:
- Copy existing file and rename it. Ensure that the extension is
.drawio.png
or.drawio.svg
. - Edit the diagram.
- Save the file.
- Optimize images with
pngquant -f --ext .png *.drawio.png
to reduce their size by 2-3x.
To create a diagram from scratch using draw.io desktop:
- In File > New > Create new diagram, select Blank diagram.
- In File > Save As, select Editable Bitmap .png, and save with
.drawio.png
extension. - To improve image quality, in File > Properties, set Zoom to 200%.
- To save the file with the new zoom setting, select File > Save.
- Optimize images with
pngquant -f --ext .png *.drawio.png
to reduce their size by 2-3x.
DO NOT use the File > Export function. The diagram should be embedded into .png
for easy editing.
Last modified August 23, 2024: Ensure frontmatter is consistent (
e47101dc
)