2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

nodejsでMarkdownファイルを署名入りでPDF化する

Posted at

markdown-pdfを利用し、Markdown記法で書かれたREADMEを署名付きでPDF化したいと思います。

1. markdown-pdfをインストール

グローバルインストールしておくと便利です

npm install -g markdown-pdf

2. footerファイルを用意

running.js というファイルを作りフッター情報を記載します。(header情報も記載できます)

exports.header = null;

exports.footer = {
        height: "1cm",
        contents: function(pageNum, numPages) {
          return "<p><span style='font-size:10px; float:right;'>copyright © 2018 HogeHoge All Right Reserved</span></p>"
        }
    };

3.PDF化

markdown-pdf -h running.js <markdown-file-path> でPDF化できます。(markdown-pdf <markdown-file-path> で署名なしになります)

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?