ReLaXed is a free command line tool to create PDF using HTML, Pug in real time. This is a command line tool that works in a very different way. It takes the name of the HTML or Pug file that you are editing and after seeing any changes in that it keeps updating the corresponding PDF file. And not only the main HTML file but if any other companion file changes, then it makes the changes in the final PDF file too. You can use this tool to create a PDF file from HTML in WYSIWYG manner. And not just HTML if you know Pug which is a shorthand for HTML, you can use that as well to create PDF files.
RelaXed runs from the command line and keeps watching a file on which you are working. It just requires Node.js to work and for the installation. There is just a single command to start it and then you can create HTML file in your favorite code editor. And along with the code editor, you can use a PDF viewer that supports auto refresh capabilities.
Using this Free Command Line tool to Create PDF using HTML, PUG in Real Time:
RelaXed is a simple and open source tool to create PDF using HTML, Pug in real time. However, to set it up on your PC, you must be familiar with Node.js commands. Currently you can’t install it globally using the single command. You will have to install it using its source. But in future updates, you will be able to do that.
Here is how to use this command line tool to create PDF using HTML, Pug.
Step 1: Get the repository of RelaXed from GitHub using this link. After that, you can extract it to some location of your choice and then open a command prompt window there.
Step 2: Run the following command to install the node modules for RelaXed.
Step 3: Now, to access RelaXed from command line, you can run this command. After running this command, you can access it from any location of your PC.
npm link --unsafe-perm=true
Step 4: Now, open the folder where you have some HTML files. Or you can even start from the scratch. Create a random file, say “test.html”. After that, you can run command for RelaXed like this.
Step 5: Now, you can open “test.html” in code editor and type some code and save it. It will detect this change and will immediately compile the corresponding PDF file. You can open that in Chrome browser. Now, you can place the code editor and browser window (with PDF file) side by side. The changes you make in the HTML file will reflect in the PDF file. You can refresh the browser page to see that.
That is all about this free command line tool to create PDF using HTML, Pug file. You can easily use it to create a PDF file from raw HTML automatically. And as you make any changes in the HTML or Pug file, it will update them in the PDF immediately.
If you want to create a PDF file directly from a HTML or a Pug file then try RelaXed. Using this tool, you can even get the functionality of WYSIWYG HTML editor which shows the output in PDF format. Even though there are some HTML to PDF converter there but they don’t work like RelaXed. So, if you want to try this new tool to convert HTML to PDF with ease then this post will help you.