Mkdocs with Scribble
Intro
Instead of changing CSS style for Your Racket projects documentation, You may be interested in compiling Markdown files generated form Scribble source into HTML documentation website.
Creating MkDocs project
-
Create
docsdirectory andmkdocs.ymlconfig file in current directory, along with a dummyindex.mdfile indocsfolder.mkdocs new . -
Edit the name of the project.
Replace
Racket-Projectwith your project name.--- site_name: Racket-Project
Building Scribble
Generate markdown files form scribble documentation.
Replace Racket-Project.scrbl with path to your scribble documentation main source file.
scribble --markdown --dest ./docs --dest-name index.md Racket-Project.scrblBuilding Markdown
Compile HTML documentation from the markdown source.
mkdocs buildHTML files should appear in the site directory.
Running the server
Some features, like search for example are only available when running the mkdocs server.
mkdocs serveCaveats
Some scribble functions do not look good or work correctly for markdown-to-HTML compilation by MkDocs.
-
table-of-contents- looks like a source block -
index-section- letter links do not work
Example configuration
site_name: Racket-Ebuild
site_author: xgqt@riseup.net
site_description: library to ease ebuild creation
site_url: https://gitlab.com/gentoo-racket/racket-ebuild
repo_name: gentoo-racket/racket-ebuild
repo_url: https://gitlab.com/gentoo-racket/racket-ebuild
plugins:
- search
theme:
name: material
extra:
social:
- icon: fontawesome/brands/gitlab
link: https://gitlab.com/gentoo-racket/racket-ebuild