# vue-pdf > Create PDF documents using Vue components — a Vue 3 renderer for the browser > and the server, ported from react-pdf. Flexbox layout via Yoga, a full text > engine with hyphenation and bidi, SVG, images, fillable AcroForm fields, and > Tailwind-style utilities. Install: `npm install @vuepdf/renderer` (Nuxt: add `@vuepdf/nuxt` to `modules`). Docs: https://vue-pdf.sanusi.dev · Repository: https://github.com/Boluwatife2904/vue-pdf Packages: @vuepdf/renderer (core), @vuepdf/nuxt (Nuxt module), @vuepdf/math (LaTeX), @vuepdf/mermaid (diagrams). This file contains the full documentation as markdown. # Getting Started ## vue-pdf Source: https://vue-pdf.sanusi.dev > Create PDF files using Vue — a Vue renderer for building PDF documents on the browser and server. Port of react-pdf to the Vue ecosystem. A Vue 3 port of `react-pdf`. Compose PDF documents using familiar Vue SFCs — write ``, ``, ``, and `` just like you would build any Vue app. Works on the browser and server. ```bash pnpm add @vuepdf/renderer ``` #### Vue Component Model Declare PDF documents using 30+ Vue primitives — Document, Page, View, Text, Image, Canvas, SVG, forms, and more. #### Flexbox Layout Powered by Yoga Layout (same engine as React Native). Every `` is a flex container. #### Browser + Server Dual platform support. Use `usePDF` and `` in the browser, or `renderToFile` on the server. #### Nuxt Auto-Imports With `@vuepdf/nuxt`, all 30+ components and composables are auto-imported with zero config. #### Rich Text Engine Advanced text layout with hyphenation, justification, RTL/bidi support, and custom font handling. #### TypeScript First Fully typed components, composables, and public API. Intellisense coverage across the entire package. #### SVG & Canvas Embed vector graphics with full SVG support (Path, Rect, Circle, gradients, markers) and `` drawing. #### Forms & Annotations Create fillable [AcroForm PDFs](https://vue-pdf.sanusi.dev/guide/forms) — TextInput, Checkbox, Select, List, FieldSet — plus Note annotations. #### Extensions Optional packages for LaTeX math (`@vuepdf/math`) and Mermaid diagrams (`@vuepdf/mermaid`). ### Quick Example Create your first PDF document in seconds: ```vue [app.vue] ``` --- ## Installation Source: https://vue-pdf.sanusi.dev/installation > Get up and running with vue-pdf — install via npm, pnpm, or yarn and configure the Nuxt module for auto-imports. Install the core `@vuepdf/renderer` package using your preferred package manager: ```bash [pm.name] pm.cmd ``` ### Nuxt Setup For Nuxt projects, add `@vuepdf/nuxt` to the `modules` array in your `nuxt.config.ts`: ```ts [nuxt.config.ts] export default defineNuxtConfig({ modules: ['@vuepdf/nuxt'], }) ``` That's it. The module auto-registers all 30+ components (``, ``, ``, ``, ``, SVG primitives, form components, and more) plus the `usePDF`, `pdf()`, `Font`, and `StyleSheet` utilities — no explicit imports needed. It also configures the parts you would otherwise have to wire by hand: - Transpiles the vue-pdf packages for Vite. - Registers a Vue SFC plugin with Nitro, so a [server route](https://vue-pdf.sanusi.dev/api/render-to-stream) can import your document `.vue` file and render a PDF on the server. - Resolves every component through a single copy of the renderer. Loading two copies gives you two injection contexts, which silently produces a blank PDF. > Server-side PDF rendering in Nuxt needs this module. If you configure components and `build.transpile` manually instead, client-side rendering works but `server/` routes that import a `.vue` document will fail to build. > Both the `@vuepdf/nuxt` module and the `@vuepdf/renderer` package have **Vue 3** and **Nuxt 3** as peer dependencies. Make sure your project has them installed. ### Vue (Without Nuxt) Import components directly from the renderer package: ```vue [App.vue]