Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
# Changelog

## 0.1.2

### Added

- 新增 `ParsedPoint` / `ParsedPosition` / `Positioned<T>` / `PositionedMarkdownRoot` / `PositionedMarkdownNode` 公开类型
- `parseMd` 返回类型收紧为 `PositionedMarkdownRoot`,在 API 边界表达"所有解析节点都带 `position` 与 `start/end.offset`"的运行时契约
- README 增加"位置契约"小节

### Tests

- 新增 `__tests__/position.spec.ts`,参数化覆盖 24 个节点类型(frontmatter / heading / thematicBreak / blockquote / list / task list / table / strikethrough / inline code / code block / hard break / autolink / link / image / reference / definition / html / math / directive 等),递归断言每个节点的 `position` 完整
- `__tests__/types/package-exports.{mts,cts}` 验证 `parseMd(...).position.start.offset` 编译为 `number`

## 0.1.0

### Added
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@lint-md/parser",
"version": "0.1.1",
"version": "0.1.2",
"description": "lint-md 的解析器,基于 remark 生态,将 Markdown 字符串转换成 AST",
"author": "yuzhanglong <loveyzl1123@gmail.com>",
"contributors": [
Expand Down