#169
gdtest_sec_multi
OK
CONFIG
Multiple custom sections: Examples, Tutorials, and Recipes.
Multiple custom sections: Examples + Tutorials + Recipes. Three different section dirs, all configured via sections list. All should appear as separate nav sections.
Build Mode
● Has great-docs.yml
This package ships a pre-supplied config.
The great-docs init step is skipped and
great-docs build uses the spec-defined configuration directly.
Tests specific config options and their rendered output.
Dimensions
N6
N6Multiple sectionssections
Source Files
examples/
demo.qmd
--- title: Demo Example --- # Demo Example A demonstration example for the multi-section package.
gdtest_sec_multi/
__init__.py
"""Test package for multiple custom sections.""" from .core import combine, multi_demo __all__ = ["combine", "multi_demo"]
core.py
"""Core multi_demo/combine functions."""
def multi_demo(x: int) -> int:
"""Run a multi-section demo with the given input.
Parameters
----------
x : int
The input value for the demo.
Returns
-------
int
The demo result doubled.
Examples
--------
>>> multi_demo(5)
10
"""
return x * 2
def combine(a: str, b: str) -> str:
"""Combine two strings with a separator.
Parameters
----------
a : str
The first string.
b : str
The second string.
Returns
-------
str
The combined string.
Examples
--------
>>> combine("hello", "world")
'hello-world'
"""
return f"{a}-{b}"recipes/
quick.qmd
--- title: Quick Recipe --- # Quick Recipe A quick recipe for common tasks.
tutorials/
basics.qmd
--- title: Basics Tutorial --- # Basics Tutorial A tutorial covering the basic concepts.
README.md
# gdtest-sec-multi Test multiple custom sections.
great-docs.yml
sections:
- title: Examples
dir: examples
- title: Tutorials
dir: tutorials
- title: Recipes
dir: recipes