Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/alexknauth/scribble-code-examples

A scribble examples form that works for non-s-expression languages
https://github.com/alexknauth/scribble-code-examples

documentation-tool racket

Last synced: about 1 month ago
JSON representation

A scribble examples form that works for non-s-expression languages

Awesome Lists containing this project

README

        

# scribble-code-examples
A scribble examples form that works for non-s-expression languages

Documentation: https://docs.racket-lang.org/scribble-code-examples/index.html

This repository contains two packages:
- `scribble-code-examples-lib`, contains the `scribble-code-examples` module but no docs or tests
- `scribble-code-examples`, contains the documentation and tests

```racket
(require scribble-code-examples)
```

In a Scribble Documentation file, writing this:
```racket
@code-examples[#:lang "at-exp racket" #:context #'here]|{
(+ 1 2)
@+[1 3]
}|
```

Produces output that shows a Repl interaction like this:
```racket
> (+ 1 2)
3
> @+[1 3]
4
```