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 🙏

© 2024 – Pkg Stats / Ryan Hefner

http-server-md-template-blank

v1.2.0

Published

Blank template skeleton for http-server-md

Downloads

8

Readme

# http-server-md-template-blank

NPM Version Build Status Downloads Stats

Blank template skeleton for http-server-md, used to populate new template modules by sermit init-template.

README & DOCS TODO

Installation

npm badge

pnpm add http-server-md-template-blank

Developing

pnpm gen-readme // update README.md
pnpm docs // update DOCUMENTATION.md
pnpm test // lint & mocha
pnpm update-deps // bump all deps

Release History

See CHANGELOG.md for more information.

License

Distributed under the MIT license. See LICENSE.md for more information.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

API Reference

The standalone JSDoc reference can be found in DOCUMENTATION.md

Modules

Constants

Functions

http-server-md-template-blank

Blank template skeleton for http-server-md, serving as a reference for the required structure.

Used by the sermit CLI app to create an empty template repo via the init-template command.

License: MIT

ASSETS_BUILD_PATH

Artifacts are stored in & resolved from the public/ folder within the project root by default.

Kind: global constant

ASSETS

Static asset (files & folders) definition. Sources prefixed with ~ are resolved with requireDynamicModule.

{ 'dest/path': 'src/path' }

Kind: global constant

STYLES_BUILD_PATH

Artifacts are stored in & resolved from the public/ folder within the project root by default.

Kind: global constant

STYLES

SCSS style definition, { dest: src }

Kind: global constant

NAME

Unique name to identify template; should form the package name when prefixed with http-server-md-template-.

Kind: global constant

PUBLIC_PATH

Absolute path to rendered resources folder, ready for serving.

Kind: global constant

INCLUDE_PATH

Nunjucks templates are in res/templates within the template root by default.

Kind: global constant

TEMPLATE

Recommended filename

Kind: global constant

TEMPLATE

Recommended filename

Kind: global constant

getConfig([userConfig]) ⇒ Sermit~Config

Combine the provided & default configurations as-needed.

Kind: global function
Returns: Sermit~Config - config

| Param | Type | Default | Description | | --- | --- | --- | --- | | [userConfig] | Sermit~Config | {} | provided configuration |

genImageMarkdown(params) ⇒ string

Generate a markdown string to display an image at relPath.

Kind: global function
Returns: string - md

| Param | Type | Description | | --- | --- | --- | | params | object | params | | params.relPath | string | path relative to content root path. | | params.name | string | image alt text. |

genRawSrcMarkdown(params) ⇒ string

Generate a markdown string to render raw file contents.

Kind: global function
Returns: string - md

| Param | Type | Description | | --- | --- | --- | | params | object | params | | params.srcPath | string | path to file, resolvable locally via fs |

renderPageDirectory(templateConfig) ⇒ Sermit~Renderer

Directory listing renderer.

Kind: global function
Returns: Sermit~Renderer - renderer

| Param | Type | Description | | --- | --- | --- | | templateConfig | Config | template config data. |

renderPageFile(templateConfig) ⇒ Sermit~FileRenderer

Single file renderer.

Kind: global function
Returns: Sermit~FileRenderer - renderer

| Param | Type | Description | | --- | --- | --- | | templateConfig | Config | template config data. |