markdown_description_list
0.2.0, released 4 months ago by dartcommunity.dev
Adds support for Markdown description/definition lists to the markdown package
What it does
Provides a Syntax class that can be added to markdown's block syntaxes to parse description lists. It renders them as HTML definition lists.
AI-written summary of version 0.2.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to parse or render Markdown that contains definition lists
- You are already using the markdown package and want minimal extra code
Skip it when
- You are not using markdown or need a full Markdown parser replacement
- You need advanced Markdown extensions beyond description lists
Strengths
- Simple API, no build_runner or codegen
- Works with existing markdown package
- Supports custom term limits and indentation rules
Weaknesses
- Only supports description lists, no other extensions
- Requires markdown ^7.3.1 and Dart 3.10+
- No UI widgets, only parsing logic
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 2
Add markdown and markdown_description_list to pubspec, import the library, and include DescriptionListSyntax in Document or markdownToHtml
import 'package:markdown/markdown.dart' as md;
import 'package:markdown_description_list/markdown_description_list.dart';
final document = md.Document(blockSyntaxes: [const DescriptionListSyntax()]);
final html = md.markdownToHtml('''
Term
: Description
''', blockSyntaxes: [const DescriptionListSyntax()]);Alternatives
Packages that do the same job and could replace markdown_description_list.
- fast_immutable_collections
Fast immutable lists, sets, maps, and multimaps for Dart
91Compare - trotter
Classes for combinatorics pseudo-lists like permutations, combinations, and subsets.
76Compare - html2md
Converts HTML strings or DOM nodes to CommonMark‑compatible Markdown.
50Compare - dart_markdown
A portable Markdown library written in Dart that parses Markdown into AST and HTML.
50Compare
Works with
Packages commonly used together with markdown_description_list: ones it builds on, ones built on it, and its own family.