JSPM

@maiscrm/vuepress-plugin-exportpdf

0.1.3
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 20
  • Score
    100M100P100Q26056F
  • License MIT

Export your VuePress site to a PDF file with outline

Package Exports

  • @maiscrm/vuepress-plugin-exportpdf

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@maiscrm/vuepress-plugin-exportpdf) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

vuepress-plugin-exportpdf

Inspired by vuepress-plugin-export.

This plugin requires VuePress >= 1.0.0-alpha.44.

Features

  • Merge all of your pages automatically.
  • Create outline by your sidebar.
  • Inject page numbers.

Install

npm i @maiscrm/vuepress-plugin-exportpdf

Usage

Using this plugin:

// .vuepress/config.js
module.exports = {
  plugins: [
    [
      '@maiscrm/vuepress-plugin-exportpdf',
      {
        themeConfig: {
          navbar: false,
          nextLinks: false,
          prevLinks: false,
          sidebar: [
            'docs/',
            {
              title: 'Plugin',
              children: [
                'docs/plugin/',
                'docs/plugin/using-a-plugin'
              ]
            }
          ]
        }
      }
    ]
  ]
}

Then run:

vuepress exportpdf [path/to/your/docs]

Development

# Note that this package is powered by [puppeteer](https://github.com/GoogleChrome/puppeteer), if you are in a mysterious wall, consider setting this [environment variables](https://github.com/GoogleChrome/puppeteer/blob/v1.11.0/docs/api.md#environment-variables) before installation.
export PUPPETEER_DOWNLOAD_HOST=https://npm.taobao.org/mirrors
yarn install
yarn exportpdf