When using this blog theme, it is recommended to use Vs Code or Obsidian. Both tools can effectively add Frontmatter information to files and support Markdown text writing, as well as Picgo file upload tool.
In my opinion, when writing blogs in markdown, it is essential to automatically generate basic frontmatter. In Vscode, you can choose to use plugins and code snippets to achieve this functionality, each with its own advantages and disadvantages.
Using plugins can automatically generate when creating a new document, but some fields cannot be modified.
Using code snippets allows for custom fields, but requires using shortcut commands to generate and manually update the last updated date of the article.
I personally recommend using code snippets without relying on plugins.
Automatically Adding Frontmatter Information in VsCode#
Reference: Snippets in Visual Studio Code
Bottom left corner -> Settings -> Select Add User Snippets
Then select New Global Snippets
Enter the snippet file name and create the file
{
"Print to console": {
"scope": "md,markdown",
"prefix": "mf",
"body": [
"---",
"title: ${0:$TM_FILENAME_BASE}",
"date: $CURRENT_YEAR-$CURRENT_MONTH-$CURRENT_DATE $CURRENT_HOUR:$CURRENT_MINUTE:$CURRENT_SECOND",
"description:"
"---"
],
"description": "Log output to console"
}
}
After configuring, in a markdown file, type mf
and press tab
to generate frontmatter information.
Others#
More Vscode writing tips: Markdown and Visual Studio Code