Skip to content

Commit 0e932c8

Browse files
committed
add typos.yal
Signed-off-by: Andrei Gherghescu <[email protected]>
1 parent 00fc82c commit 0e932c8

File tree

3 files changed

+30
-3
lines changed

3 files changed

+30
-3
lines changed

.github/workflows/typos.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Typos
2+
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
branches: [ main ]
7+
push:
8+
branches: [ main ]
9+
10+
jobs:
11+
typos:
12+
name: Check for typos
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: crate-ci/typos@master

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ Alternatively, enable only the `kaleido` feature and manually install Kaleido.
148148
# Cargo.toml
149149

150150
[dependencies]
151-
plotly = { version = "0.12", features = ["kaleido"] }
151+
plotly = { version = "0.13", features = ["kaleido"] }
152152
```
153153

154154
With the feature enabled, plots can be saved as any of `png`, `jpeg`, `webp`, `svg`, `pdf` and `eps`. Note that the plot will be a static image, i.e. they will be non-interactive.

docs/book/src/getting_started.md

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,15 +91,26 @@ plot.write_image("/home/user/plot_name.ext", ImageFormat::PNG, 1280, 900, 1.0);
9191

9292
The extension in the file-name path is optional as the appropriate extension (`ImageFormat::PNG`) will be included. Note that in all functions that save files to disk, both relative and absolute paths are supported.
9393

94-
## Saving Plots
94+
## Saving Plots with Kaleido (legacy)
9595

9696
To add the ability to save plots in the following formats: png, jpeg, webp, svg, pdf and eps, you can use the `kaleido` feature. This feature depends on [plotly/Kaleido](https://github.com/plotly/Kaleido): a cross-platform open source library for generating static images. All the necessary binaries have been included with `plotly_kaleido` for `Linux`, `Windows` and `MacOS`. Previous versions of [plotly.rs](https://github.com/plotly/plotly.rs) used the `orca` feature, however, this has been deprecated as it provided the same functionality but required additional installation steps. To enable the `kaleido` feature add the following to your `Cargo.toml`:
9797

9898
```toml
9999
[dependencies]
100-
plotly = { version = "0.12", features = ["kaleido"] }
100+
plotly = { version = "0.13", features = ["kaleido"] }
101101
```
102102

103+
## Static Image Export with WebDriver (recommended)
104+
105+
For static image export using WebDriver and headless browsers, you can use the `plotly_static` feature. This feature supports the same formats as Kaleido (png, jpeg, webp, svg, pdf) but uses WebDriver for the static export proccess. To enable static export, add the following to your `Cargo.toml`:
106+
107+
```toml
108+
[dependencies]
109+
plotly = { version = "0.13", features = ["static_export_default"] }
110+
```
111+
112+
The `static_export_default` feature includes Chrome WebDriver support with automatic download. For Firefox support, use `static_export_geckodriver` instead. See the [Static Image Export](../fundamentals/static_image_export.md) chapter for a detailed usage example.
113+
103114
## WebAssembly Support
104115

105116
As of v0.8.0, [plotly.rs](https://github.com/plotly/plotly.rs) can now be used in a `Wasm` environment by enabling the `wasm` feature in your `Cargo.toml`:

0 commit comments

Comments
 (0)