Nerfed Poet Melancholia


    1.0.4 • Public • Published

    Pajama-ssg 💤

    This is a Simple Static Site Generator (SSG) version_1.0.1

    All you have to do is provide the content in a text file, type the filename on the command line and run it! This Pajama-ssg will automatically convert it to an HTML file. It's so simple and easy that you can start creating web pages right away, even in your pajamas!


    • Generate static HTML file(s) from .txt file(s)
    • Read .txt files inside folder(s) and generate HTML file(s)
    • All generated HTML files are stored in the dist folder
    • Convert the file name as the title in the head tag
    • Convert the first line in the .txt file as an h1 tag
    • Convert Markdown files into HTML(With italic, bold, and horizontal rule)

    Option Features

    • type -s or -stylesheet on the command line, it will be converted to a style tag link
    • type -l or -lang on the command line, it will generate the lang attribute on the root element
    • type -c or --config on the command line, it will get the flag values from your config JSON file.


    Install npm package:

    • Open Terminal or CLI
    • Go to the directory/folder you would like to add the program
    • Type the npm i pajama-ssg command

    npm package:


    $npx pajama-ssg -i <path> or $npx pajama-ssg -input <path>

    These allows you to the text file to a HTML file. Please type file name into the <path>.

    $npx pajama-ssg -i <folder name>

    If your text file is in a folder, you can type folder name instead of text file name.
    This SSG tool checkes inside the folder.

    $npx pajama-ssg -input <path> -stylesheet <URL> or $npx pajama-ssg -i <path> -s <URL>

    You are able to add stylesheet. Please type the URL or path into the <URL>.

    $npx pajama-ssg -c config-file.json

    You are able to pass a configuration JSON file.


    Option Function
    -i, --input input file
    -c, --config receive a config JSON file and get flags from it
    -s, --stylesheet input the path for generating the stylesheet path
    -l, --lang input the language for the lang attribute
    -v, --version display version


    Input file


    Type the on command line

    npx pajama-ssg -i test.txt -s (This example uses water.css)


     Silver Blaze
     I am afraid, Watson, that I shall have to go,” said Holmes, as we
     sat down together to our breakfast one morning.
     “Go! Where to?”
     “To Dartmoor; to King’s Pyland.”
     I was not surprised. Indeed, my only wonder was that he had not already been mixed up in this extraordinary case, which was the one topic of conversation through the length and breadth of England.


    <!DOCTYPE html>
    <html lang="en">
        <meta charset="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        <h1>Silver Blaze</h1>
          I am afraid, Watson, that I shall have to go,” said Holmes, as we sat down
          together to our breakfast one morning.
        <p>“Go! Where to?”</p>
        <p>“To Dartmoor; to King’s Pyland.”</p>


    Mizuho Okimoto


    This project is licensed under the MIT License - see the file for details


    Thank you for investing your time in contributing to our project!
    Your contribution will invigorate this wonderful open source community and create even better ones. Your contribution is greatly welcomed!
    For details on contributing to this repository, see the contributing guide.




    npm i pajama-ssg

    DownloadsWeekly Downloads






    Unpacked Size

    686 kB

    Total Files


    Last publish


    • mizuho