---
title: Bengal 0.1.5
description: Named directive closers, media embeds, faster navigation, remote content sources, and comprehensive validation
type: changelog
date: 2025-12-22
draft: false
lang: en
tags: [release, changelog, directives, media, performance, validation]
keywords: [release, 0.1.5, directives, media, youtube, navigation, validation, content-layer]
category: changelog
---

# Bengal 0.1.5

**Key additions:** Named directive closers, media embeds (YouTube, Vimeo, CodePen), remote content sources, 10x faster navigation rendering, and standalone validation commands.

---

## Highlights

### Named Directive Closers

No more counting fence characters. Close directives by name:

```markdown
:::{tabs}
:::{tab-item} Python
Code here...
:::{/tab-item}

:::{tab-item} JavaScript  
More code...
:::{/tab-item}
:::{/tabs}
```

Standard `::::` closers still work. Named closers are opt-in for complex nesting.

### Media Embeds

Embed videos, code playgrounds, and terminal recordings:

```markdown
:::{youtube} dQw4w9WgXcQ
:::

:::{vimeo} 148751763
:::

:::{codepen} aWJVwy
:theme: dark
:::

:::{asciinema} 335480
:speed: 2
:::
```

Also available: `gist`, `codesandbox`, `stackblitz`, `figure`, `audio`, `video` (self-hosted).

Privacy-first: YouTube uses `youtube-nocookie.com`, Vimeo uses Do Not Track.

### Remote Content Sources

Fetch content from GitHub, REST APIs, or Notion:

```yaml
# bengal.toml
[collections.external-docs]
loader = "github"
repo = "owner/repo"
path = "docs/"
```

```bash
bengal sources fetch    # Pull remote content
bengal sources status   # Check availability
```

Supported: `local`, `github`, `rest`, `notion`.

### Faster Navigation

Navigation tree now renders in microseconds instead of milliseconds. The nav structure is computed once and cached per version.

- Template access: ~230ns (was ~2ms)
- First render overhead: ~80μs

### Validation Commands

Standalone validation without a full build:

```bash
bengal validate                    # Check all files
bengal validate --file docs/       # Check specific path
bengal validate --watch            # Continuous mode
bengal fix                         # Auto-fix common issues
```

### Page Visibility

Control where pages appear:

```yaml
---
hidden: true  # Hide from nav, listings, sitemap, search, RSS
---
```

Or granular control:

```yaml
---
visibility:
  menu: false
  sitemap: false
  search: true
---
```

---

## Other Improvements

### Dev Server

- **Rust-based file watching** via `watchfiles` (10-50x faster change detection)
- **Pre/post build hooks**: run custom commands via `pre_build` and `post_build` config
- **Subprocess builds**: crashes don't take down the server

### Cache & Performance

- **Zstd compression**: caches are 12-14x smaller, load 10x faster (Python 3.14's PEP 784)
- **Parallel health checks**: 50-70% faster validation
- **Config hash invalidation**: cache auto-invalidates when configuration changes

### Typography

- **Instrument Serif** as default display font
- Improved heading weights (h1=800, h2=700, h3/h4=600)
- Body line-height bumped to 1.7

### Project Structure

Build artifacts now live in `.bengal/` instead of scattered locations:

```tree
.bengal/
├── cache/
├── templates/    # Jinja bytecode cache
└── ...
```

### Autodoc

- **Incremental rebuilds**: only regenerate pages when source files change
- **Strict mode**: `autodoc.strict = true` for fail-fast in CI/CD

### Template Validation

Catch syntax errors before content discovery:

```toml
[build]
validate_templates = true
```

---

## Upgrading

```bash
uv pip install --upgrade bengal
# or
pip install --upgrade bengal
```

All changes are backward compatible. Named directive closers are opt-in, caches auto-migrate to zstd format, and existing configs work unchanged.

---

## Links

- [Documentation](https://github.com/lbliii/bengal)
- [Issue Tracker](https://github.com/lbliii/bengal/issues)
- [Full Changelog](https://github.com/lbliii/bengal/blob/main/changelog.md)
