Sha256: 8821a7bbe128b1ce82de6927a904248100c7e31b876eac3d5176ca9b165d93e4

Contents?: true

Size: 1.44 KB

Versions: 3

Compression:

Stored size: 1.44 KB

Contents

# Demo block nicknames

@import example-document-opts.md
```opts :(document_opts)
pause_after_script_execution: true
```

## Blocks with no name
::: This block has no name.
::: The code block is displayed.

```bash
echo This block has no name.
```

## Blocks with nicknames
::: The code block is displayed.
::: The nickname can be used to require the block.

```bash :[A]
echo 'This block has a nickname: [A].'
echo The full block is displayed in the menu.
```

### Nicknames in documents
::: Execute this block that requires the block above by its nickname.
```bash :[B] +[A]
echo 'This block has a nickname: [B].'
echo 'This block requires block [A].'
```

### Nicknames from the command line
Block `[A]` is called from the command line.
```bash
mde examples/nickname.md '[A]'
```

## Blocks with hidden names
### There is a hidden block here.
::: This block has a hidden name: (C).
::: This block does not appear in the menu.
::: This block requires the block above by its nickname.
```bash :(C) +[A]
echo 'This block has a hidden name: (C).'
echo This block is hidden from the menu.
echo 'This block requires block [A].'
```

### Hidden names from the command line
Block `(C)` is called from the command line.
```bash
mde examples/nickname.md '(C)'
```

### Block without a name
::: This block does not have a name.
::: It requires hidden block (D).
```bash +(D)
echo "Block without a name"
```
::: This block has a hidden name: (D).
```bash :(D)
echo "Block D"
```

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
markdown_exec-2.7.2 examples/nickname.md
markdown_exec-2.7.1 examples/nickname.md
markdown_exec-2.7.0 examples/nickname.md