Skip to content

Commit

Permalink
feat: add example with ignore to playpen
Browse files Browse the repository at this point in the history
  • Loading branch information
jsjoeio committed Mar 29, 2020
1 parent 051382a commit 5382d4b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/meta/playpen.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@ This allows the reader to both run your code sample, but also modify and tweak i
```
````

Additionally, you can add `ignore` if you want `mdbook` to skip your code when it builds and tests.

````markdown
```rust,editable,ignore
//...place your code here
```
````

## Using it with docs

You may have noticed in some of the [official Rust docs][official-rust-docs] a button that says "Run", which opens the code sample up in a new tab in Rust Playground. This feature is enabled if you use the #[doc] attribute called [`html_playground_url`][html-playground-url].
Expand Down

0 comments on commit 5382d4b

Please sign in to comment.