npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

static-site-converter

v1.0.3

Published

txt-to-html static site generater

Readme

Goal

This is mainly a tool that converts TXT files into static web pages. Additionally, Markdown(MD) files will also get converted into HTML. Any bold text in the MD file will also appear bold in the HTML file. Also, any --- or longer variations from Markdown files will become horizontal rule/line in the HTML files. Any link syntax (such as [text](link)) in Markdown files will be converted into a HTML link. If you have a static folder under the input folder directory specified via command, all fo its content will be copied to the static folder in the output directory (defualt: dist folder in your current directory).

Getting Started

Please first have Node.js installed on your machine.

  1. While inside an empty folder, download the tool via command npm i static-site-converter in command line (such as cmd or PowerShell)
  2. Run command cd node_modules\static-site-converter to get into the tool's root folder
  3. You can now use it! See the next Usage section for more details

Usage

The user can provide one or more TXT/MD files to convert into HTML file(s) of the same names. Sample test files are in "test_files" folder. This tool is run by entering commands in command line.

Use --input or -i to specify path to a TXT/MD file or a folder with TXT/MD files, and this tool will convert them into HTML files in 'dist' folder. If the dist folder doesn't exist at the current directory, one will be created. If it exist, it will be deleted first to clean old output before being recreated. Example: node index -i ./test_files

If you path has spaces for a file or folder, please use '' around the name(s). Example: node index -i ./'a folder with space in the name'

Other options:

  1. --version or -v This provides tool name and its version.

  2. --output or -o Use this to specify an output directory instead of using the dist folder. If the directory is invalid, output directory is set back to the default dist folder. Note: For safety, the directory specified by this option is never deleted by the tool! Example: -o ./myFolder

  3. --stylesheet or -s Use this to specify url of the stylesheet to use. Example: -s https://cdnjs.cloudflare.com/ajax/libs/tufte-css/1.8.0/tufte.min.css

  4. --help or -h This shows the help guide.

  5. --lang or -l Use this to specify the language of the HTML files. Example: -l fr for French

  6. --config or -c Use this to specify JSON config file that has a list of options. If the same option is provided in config file and command line argument, the command line argument will be overridden. Example: -c ./config_file/ssg-config.json for below options to be added. config.json

{
  "input": "./test_files",
  "output": "./out",
  "stylesheet": "https://cdnjs.cloudflare.com/ajax/libs/tufte-css/1.8.0/tufte.min.css",
  "lang": "fr-CA",
  "future-feature": "invalid option will be ignored"
}

Contributing

Please see CONTRIBUTING.md.