English
About this handbook

This handbook belongs to the template Example for QuartzControl. It explains the template and, at the same time, shows everything it can do.

The text here comes from a Markdown file, not from the configuration.

Code blocks

```ts
export function greet(name: string): string {
  return `Hello, ${name}`
}
```
export function greet(name: string): string {
  return `Hello, ${name}`
}

Without a language

```
Plain text without highlighting.
```
Plain text without highlighting.

With a title

A title= after the language puts a label above the block — handy for naming the file the excerpt belongs to.

```yaml title="quartz.config.yaml"
configuration:
  pageTitle: Example
```
quartz.config.yaml
configuration:
  pageTitle: Example

Long lines

A code block does not wrap long lines, it scrolls: breaking a shell command costs more than scrolling it.

npx quartz build --serve --port 8080 --wsPort 3001 --bundleInfo --verbose --directory content

In this template

Three differences from the default:

  • The language sits at the top left of the block, as an ::after in the stylesheet — so it does not end up in a copy.
  • The copy button is 44 px across and appears on hover, on focus and permanently on devices without a pointer. Out of the box it is only visible on hover and therefore unreachable on a smartphone.
  • The background comes from the template, not from the syntax theme: keepBackground: false makes shiki set only the colours of the characters. That way the block fits in both colour schemes.

Read on

This page belongs to Example — the example template for QuartzControl. An overview of every area is on the English home page.

On a narrow screen the navigation is collapsed at the top.