在VuePress中导出PDF文件可以通过多种方法实现,每种方法都有其特定的优缺点。以下是一些常用的方法及其步骤: 1. 使用vuepress-plugin-export插件 vuepress-plugin-export是一个专门为VuePress设计的插件,用于将站点内容导出为PDF文件。以下是使用此插件的步骤: ...
@condorhero/vuepress-plugin-export-pdf-v2 is a VuePress 2.x plugin that allows you to export your sites to a PDF file with outlines or bookmarks.Relatedvitepress-export-pdf @condorhero/vuepress-plugin-export-pdf-v1Installationnpm install @condorhero/vuepress-plugin-export-pdf-v2 -Dthen...
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' ] } ] } } ] ] }...
module.exports:['vuepress-plugin-export',{theme:'@vuepress/default',puppeteer:{args:['--no-sandbox']},bundles:[{filter:(location)=>!location.includes('export'),dest:()=>'docs/public/export.pdf',},{filter:/\/en\///,dest:(siteConfig)=>`docs/public/${siteConfig.title}.en.pdf`,}]...
https://github.com/ulivz/vuepress-plugin-export #vuepress-plugin-export-pdf https://www.npmjs.com/package/@condorhero/vuepress-plugin-export-pdf 本地转换,速度快 导出的是整个站点docs目录下所有的文章合并为一个pdf文件 样式比较乱,有些vuepress特有的语法不支持 ...
import { defineUserConfig } from 'vuepress' import { md } from 'vuepress-plugin-md-power' export default defineUserConfig({ plugins: [ markdownPowerPlugin({ caniuse: true, pdf: true, bilibili: true, youtube: true, icons: true, }) ] })...
我也写了一个小插件,它可以将你的 vuepress 站点下载成一个 pdf 文件:vuepress-plugin-export-site 源码 使用ready 选项 借助puppeteer 和easy-pdf-merge 实现:从上下文中拿到路由信息,然后使用 puppeteer 遍历访问并下载,最后合并成一个大 PDF。 因为需要下载 chromium,所以国内网络受限。我们换成了 puppeteer-cn。
我也写了一个小插件,它可以将你的 vuepress 站点下载成一个 pdf 文件:vuepress-plugin-export-site 源码 使用ready 选项 借助puppeteer 和 easy-pdf-merge 实现:从上下文中拿到路由信息,然后使用 puppeteer 遍历访问并下载,最后合并成一个大 PDF。 因为需要下载 chromium,所以国内网络受限。我们换成了 puppeteer-cn...
首先,创建一个名为vuepress-plugin-copyright的目录,然后在其中创建index.js文件,这是插件的入口。编写...
package.json "scripts": { "dev": "vuepress dev docs", "build": "vuepress build docs", "pdf": "vuepress build docs && cd docs && vuepress export" }, Warning with yarn run pdf: info Start to generate current site to PDF ... Error: net::ERR...