feat: update compose to support new frontmatter options

This commit is contained in:
Timothy Lin committed 2021-07-04 17:19:35 +08:00
commit 9378179b9e
7 files changed
+395 -53

No files matched your search

@@ -147,17 +147,9 @@ layout: PostLayout
### Compose
`scripts/compose.js` can be used to easily generate a post with pre-filled front matter.
Run `node ./scripts/compose.js` to bootstrap a new post.
The first argument is the name of the post and the second optional argument is the extension (default to .mdx)
Example code to generate the post called "My First Post" in markdown format
```
node ./scripts/compose.js "My First Post" .md
```
This will generate `./data/blog/my-first-post.md` with pre-filled front matter.
Follow the interactive prompt to generate a post with pre-filled front matter.
## Deploy