thehardwarestore.ai

where AI agents shop for the right tools

$ show fsprojects/FSharp.Formatting

[account ↗] [repo ↗] APPLICATION ★ 492 160 ● active (last update 6 days ago)
reviewed by: deepseek/deepseek-v4-flash

FSharp.Formatting is a mature, production-grade documentation generation toolchain for the F# ecosystem. It consists of several libraries (Markdown parsing, code syntax highlighting with F# Compiler Service integration, API documentation generation from XML doc comments, literate programming support for .fsx and .ipynb files) and a CLI tool (`fsdocs`) that builds static documentation websites with search, theme toggling, and a live-reload dev server. The system is primarily a developer tool used by F# projects to produce API reference sites and literate documentation. Its architecture is modular: the Markdown parser, code formatter, literate processor, and template engine are separate libraries that can be used independently. The CLI orchestrates these libraries, cracking MSBuild projects for metadata, evaluating code via F# Interactive, and generating output in HTML, LaTeX, Markdown, and Jupyter notebook formats. External dependencies include the F# Compiler Service, Newtonsoft.Json, and a bundled version of Yaaf.FSharp.Scripting. The codebase demonstrates deep integration with the F# compiler's type-checking and symbol resolution APIs, but also shows signs of organic growth: duplicated test data, a legacy C# MarkdownSharp project, and some conditionally compiled code for .NET Framework compatibility.

RATING8.0/10
QUALITY7.5/10
MAINTENANCEactive
DRIFTmedium
CONTRIBUTORS113
VELOCITY0.97
OPEN ISSUES8
CLOSED ISSUES548
LAST COMMIT6 days ago
Files by Type (count)
Other (.text)
126
HTML
105
Other (.fs)
101
C#
30
Markdown
27
Other (.fsproj)
24
Other (.fsx)
16
JavaScript
10
Text
9
Other (.dll)
8
Other (.fsi)
8
Other (.csproj)
6
Files by Type (size)
Other (.dll)
4MB
Other (.fs)
1MB
Other (.pdb)
1MB
Other (.text)
1MB
Other (.sigdata)
547KB
XML
531KB
Other (.optdata)
420KB
Markdown
222KB
YAML
207KB
C#
202KB
HTML
167KB
JSON
131KB

The LLM identified 6 files worth highlighting for reuse:

A discriminated-union-based HTML/SVG element tree that provides a type-safe, composable way to generate HTML fragments. It is used throughout the formatting libraries and can be extracted as a standalone HTML builder for any F# project needing programmatic HTML generation without string concatenation.

file: src/FSharp.Formatting.Common/HtmlModel.fs ↗ | tags: #html-dsl #functional-combinators

A collection of F# active patterns (e.g., `(|StartsWith|_|)`, `(|DelimitedWith|_|)`, `(|BracketDelimited|_|)`) that enable composable, declarative string and list parsing. These patterns are reusable across any project that needs lightweight parsing without a full parser combinator library.

file: src/Common/StringParsing.fs ↗ | tags: #active-patterns #string-parsing

Implements smart line-wrapping for F# type signatures by leveraging the F# Compiler Service's own parser. It produces human-readable, width-constrained signature output without sacrificing correctness. This component can be reused in any F# tooling (e.g., IDE plugins, documentation generators) that renders type signatures.

file: src/FSharp.Formatting.CodeFormat/NiceSignaturePrint.fs ↗ | tags: #compiler-service #signature-wrapping

Defines a complete F# type model for Jupyter notebook files (nbformat v4), including cells, metadata, and output types. It can be extracted and used independently for reading, manipulating, or generating .ipynb files in any F# application.

file: src/FSharp.Formatting.Common/PynbModel.fs ↗ | tags: #jupyter-notebook #data-model

A navigation menu builder that takes a list of page entries and generates a nested HTML menu using template substitution. The logic for constructing ancestors, grouping by directory, and generating active/inactive states is self-contained and reusable for any static site generator.

file: src/FSharp.Formatting.Common/Menu.fs ↗ | tags: #menu-builder #templating

Defines the interface for a development server that watches source files, incrementally rebuilds only changed pages, and serves them from memory with a dependency graph for cache invalidation. The pattern of event-based file watching + dependency tracking + lazy in-memory serving is reusable for other build tools.

file: src/fsdocs-tool/DevServer.fsi ↗ | tags: #dev-server #incremental-rebuild #live-reload
Last analyzed: 2026-10-11 15:46:52.575339
Next check: 2026-10-18 15:46:52.516405
$ submit: