add: 元数据提取
This commit is contained in:
@@ -4,5 +4,5 @@ public class BlogContent
|
||||
{
|
||||
public required string FileName { get; init; }
|
||||
|
||||
public required string FileContent { get; init; }
|
||||
public required string FileContent { get; set; }
|
||||
}
|
||||
|
@@ -6,5 +6,12 @@ public class BlogEssay
|
||||
|
||||
public required DateTime PublishTime { get; init; }
|
||||
|
||||
public List<string> Tags { get; } = [];
|
||||
|
||||
public required string HtmlContent { get; init; }
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return $"{Title}-{PublishTime}";
|
||||
}
|
||||
}
|
||||
|
10
YaeBlog.Core/Models/MarkdownMetadata.cs
Normal file
10
YaeBlog.Core/Models/MarkdownMetadata.cs
Normal file
@@ -0,0 +1,10 @@
|
||||
namespace YaeBlog.Core.Models;
|
||||
|
||||
public class MarkdownMetadata
|
||||
{
|
||||
public string? Title { get; set; }
|
||||
|
||||
public DateTime? Date { get; set; }
|
||||
|
||||
public List<string> Tags { get; set; } = [];
|
||||
}
|
Reference in New Issue
Block a user