Code Monkey home page Code Monkey logo

tutorial_pdf_generation's Introduction

Generate Dynamic PDFs Using React and NodeJS

Currency Converter Tutorial

This is a code repository for the corresponding article on Medium.

In this tutorial, you will learn how to generate dynamic PDFs using HTML code as a template.

Project Setup

  1. Create a new directory mkdir pdfGenerator && cd pdfGenerator
  2. Create a new React App with create-react-app client and then move into newly created directory and install dependencies cd client && npm i -S axios file-saver
  3. Create an Express server with mkdir server && cd server && touch index.js && npm init press enter a couple of times to initialize package.json and then run npm i -S express body-parser cors html-pdf to save all the necessary dependencies.
  4. Add proxy inside of client/package.json, above the dependencies, simply add “proxy”: “http://localhost:5000/", so you can call the localhost from the client.
  5. Open two different terminals: First one: go into the client directory and run npm start Second one: go into the server directory and run nodemon index.js

tutorial_pdf_generation's People

Contributors

adrianhajdin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.