---
title: React native PDF Creator – ReadyMadeCode
description: "React native PDF Creator install package react-native-html-to-pdf. import React, { Component } from 'react';\n\nimport {\n  Text,\n  TouchableHighlight,\n  View"
---

[Skip to content](https://jaeves.com/codelab/react-native-pdf-creator#main-content)

 Close

SEARCH

[Discover Jaeves for Free](https://app.jaeves.com/login)

[![jaeves-2025-logo](https://jaeves.com/hubfs/logos/jaeves-2025-logo.svg)![jaeves-2025-logo](https://jaeves.com/hubfs/logos/jaeves-2025-logo.svg)](https://jaeves.com/)

[Discover Jaeves for Free](https://app.jaeves.com/login)

Quick results for "{search\_term}"

TABLE OF CONTENTS

loading...

[Admin](https://jaeves.com/codelab/author/admin)Sep 16, 2023, 9:47:19 PM< 1 min read

# React native PDF Creator

[Previous](https://jaeves.com/codelab/how-to-create-qr-code-in-react)

<https://jaeves.com/codelab>

[Next](https://jaeves.com/codelab/how-to-get-10000-visitors-daily-on-website)

React native PDF Creator

install package [react-native-html-to-pdf](https://www.npmjs.com/package/react-native-html-to-pdf).

```
import React, { Component } from 'react';

import {
  Text,
  TouchableHighlight,
  View,
} from 'react-native';

import RNHTMLtoPDF from 'react-native-html-to-pdf';

class Example extends Component {
  async createPDF() {
    let options = {
      html: '<h1>Example PDF</h1>',
      fileName: 'example',
      directory: 'Documents',
    };

    let file = await RNHTMLtoPDF.convert(options)
    console.log(file.filePath);
  }

  render() {
    return(
      <View>
        <TouchableHighlight onPress={this.createPDF}>
          <Text>Create PDF</Text>
        </TouchableHighlight>
      </View>
    )
  }
}

export default Example;
```

[click for more React codes](https://jaeves.com/en/codelab/tag/react-native)

COMMENTS

## RELATED ARTICLES

[![logo](https://jaeves.com/hs-fs/hubfs/jaeves-logo-230917.png?width=140&height=45&name=jaeves-logo-230917.png "logo")](https://jaeves.com/)

Jaeves is a trailblazing AI-powered content generation tool that revolutionizes your content creation journey. Its user-friendly interface, extensive customization options, and innovative approach make it an invaluable asset for all your content needs. Transform your content strategy with Jaeves today.

All rights reserved

- [Privacy Policy](https://jaeves.com/privacy-policy)

```json
{
  "@context" : "https://schema.org",
  "@type" : "Organization",
  "address" : {
    "@type" : "PostalAddress",
    "addressCountry" : "Germany",
    "addressLocality" : "Speyer",
    "addressRegion" : "Rheinland-Pfalz",
    "postalCode" : "67346",
    "streetAddress" : "Gerhart-hauptmann-Str"
  },
  "knowsLanguage" : "en",
  "logo" : {
    "@type" : "ImageObject",
    "url" : "https://139767802.fs1.hubspotusercontent-eu1.net/hubfs/139767802/logo-2024-less-points.svg"
  },
  "name" : "Jaeves AI",
  "url" : "https://jaeves.com/codelab/react-native-pdf-creator"
}
```

```json
{
  "@context" : "https://schema.org",
  "@type" : "BlogPosting",
  "abstract" : "React native PDF Creator install package react-native-html-to-pdf. import React, { Component } from 'react'; import { Text, TouchableHighlight, View",
  "author" : {
    "@type" : "Person",
    "name" : "Admin"
  },
  "dateModified" : "",
  "datePublished" : "",
  "headline" : "React native PDF Creator",
  "image" : "",
  "inLanguage" : "en",
  "keywords" : "[React Native]",
  "mainEntityOfPage" : {
    "@type" : "WebPage"
  },
  "name" : "React native PDF Creator",
  "publisher" : {
    "@type" : "Organization",
    "logo" : {
      "@type" : "ImageObject",
      "url" : "https://139767802.fs1.hubspotusercontent-eu1.net/hubfs/139767802/jaeves-logo-230917.png"
    },
    "name" : "Jaeves AI"
  },
  "text" : "React native PDF Creator install package react-native-html-to-pdf. import React, { Component } from 'react'; import { Text, TouchableHighlight, View, } from 'react-native'; import RNHTMLtoPDF from 'react-native-html-to-pdf'; class Example extends Component { async createPDF() { let options = { html: 'Example PDF', fileName: 'example', directory: 'Documents', }; let file = await RNHTMLtoPDF.convert(options) console.log(file.filePath); } render() { return( Create PDF ) } } export default Example; click for more React codes",
  "url" : "https://jaeves.com/codelab/react-native-pdf-creator",
  "wordCount" : "730"
}
```

```json
{
  "@context" : "https://schema.org",
  "@type" : "BlogPosting",
  "author" : {
    "@type" : "Person",
    "name" : "Admin",
    "url" : "https://jaeves.com/codelab/author/admin"
  },
  "dateModified" : "2023-09-17T03:32:09.720Z",
  "datePublished" : "2023-09-17T01:47:19.000Z",
  "headline" : "React native PDF Creator – ReadyMadeCode",
  "mainEntityOfPage" : {
    "@id" : "https://jaeves.com/codelab/react-native-pdf-creator",
    "@type" : "WebPage"
  },
  "publisher" : {
    "@type" : "Organization",
    "logo" : {
      "@type" : "ImageObject",
      "url" : "https://jaeves.com/hubfs/logo-2024-less-points.svg"
    },
    "name" : "Jaeves AI"
  }
}
```

```json
{
  "@context" : "http://schema.org",
  "@type" : "Organization",
  "description" : "Unlock the Power of AI for Content Creation. Explore Insights, Tips, and Trends on the Jaeves.com Blog. Empower Your Writing Journey Today!",
  "logo" : "https://jaeves.com/hubfs/untitled%20(4).png",
  "name" : "Jaeves AI",
  "sameAs" : [ "https://www.instagram.com/jaeves.ai", "https://www.linkedin.com/company/jaeves-ai", "https://www.youtube.com/@Jaeves_ai", "https://www.tiktok.com/@jaeves_ai" ],
  "url" : "https://jaeves.com"
}
```