Skip to content

Commit 699d458

Browse files
authored
Release 0.4.0 (#61)
1 parent f2090ea commit 699d458

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

CHANGELOG.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10-
## [0.4.0-beta2] - 2023-07-29
10+
## [0.4.0] - 2023-08-17
11+
12+
## [0.4.0-beta.2] - 2023-07-29
1113

1214
### Added
1315

src/DocumentationGenerator/DocumentationGenerator.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
</PropertyGroup>
1010

1111
<ItemGroup>
12-
<PackageReference Include="DotMarkdown.Docusaurus" Version="0.3.0-beta" />
12+
<PackageReference Include="DotMarkdown.Docusaurus" Version="0.3.0" />
1313
<PackageReference Include="CommandLineParser" Version="2.8.0" />
1414
</ItemGroup>
1515

src/DocumentationGenerator/Program.cs

+5-8
Original file line numberDiff line numberDiff line change
@@ -264,18 +264,15 @@ private static void AddFootnote(MDocument document)
264264

265265
private static void WriteFrontMatter(DocusaurusMarkdownWriter mw, int? position = null, string? label = null)
266266
{
267-
if (position is not null
268-
|| label is not null)
269-
{
270-
var items = new List<(string, object)>();
267+
mw.WriteDocusaurusFrontMatter(GetItems());
271268

269+
IEnumerable<(string, object)> GetItems()
270+
{
272271
if (position is not null)
273-
items.Add(("sidebar_position", position));
272+
yield return ("sidebar_position", position);
274273

275274
if (label is not null)
276-
items.Add(("sidebar_label", label));
277-
278-
mw.WriteDocusaurusFrontMatter(items);
275+
yield return ("sidebar_label", label);
279276
}
280277
}
281278
}

0 commit comments

Comments
 (0)