From b8ef89db629b9de5b321d10574dc2dd76ea3769a Mon Sep 17 00:00:00 2001 From: Yashodhan Joshi Date: Tue, 5 Oct 2021 12:11:29 +0530 Subject: [PATCH] Add rust specific codeblock examples --- test_book/src/SUMMARY.md | 1 + test_book/src/rust/rust_codeblock.md | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 test_book/src/rust/rust_codeblock.md diff --git a/test_book/src/SUMMARY.md b/test_book/src/SUMMARY.md index 03cd91cf..6292fd22 100644 --- a/test_book/src/SUMMARY.md +++ b/test_book/src/SUMMARY.md @@ -26,6 +26,7 @@ - [Languages](languages/README.md) - [Syntax Highlight](languages/highlight.md) - [Rust Specific](rust/README.md) + - [Rust Codeblocks](rust/rust_codeblock.md) --- diff --git a/test_book/src/rust/rust_codeblock.md b/test_book/src/rust/rust_codeblock.md new file mode 100644 index 00000000..5fb2b724 --- /dev/null +++ b/test_book/src/rust/rust_codeblock.md @@ -0,0 +1,27 @@ +## Rust codeblocks + +This contains various examples of codeblocks, specific to rust + +## Simple + +```rust +fn main(){ + println!("Hello world!"); +} +``` + +## With Hidden lines + +```rust +# fn main(){ + println!("Hello world!"); +# } +``` + +## Editable + +```rust,editable +fn main(){ + println!("Hello world!"); +} +```