0.5.0 • Published 3 years ago

@celesta/vuepress-plugin-post-filter v0.5.0

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Vuepress-plugin-post-filter

Post filter plugin for vuepress-next

Usage

npm install vuepress-plugin-post-filter
# OR
yarn add vuepress-plugin-post-filter
// .vueprss/config.ts
export default {
  plugins: ["vuepress-plugin-post-filter"]
}

Set frontmatter in your draft:

---
draft: true
# OR
published: false
---

Now, your draft will not publish when building.

Config

// .vueprss/config.ts
export default {
  plugins: [
    [
      "vuepress-plugin-post-filter",
      {
        frontmatter: {
          draft: true,
          published: false
        },
        prodOnly: true,
      }
    ]
  ]
}