Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

serve-markdown-it-template-blank

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

serve-markdown-it-template-blank

Blank template skeleton for serve-markdown-it

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created
Source

# serve-markdown-it-template-blank

NPM Version Build Status Downloads Stats

Blank template skeleton for serve-markdown-it, used to populate new template modules by sermit init-template.

README & DOCS TODO

Installation

npm badge

yarn add serve-markdown-it-template-blank

Developing

yarn gen-readme // update README.md
yarn docs // update DOCUMENTATION.md
yarn test // lint & mocha
yarn 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

serve-markdown-it-template-blank

Blank template skeleton for serve-markdown-it, 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.

Constants

ASSETS_BUILD_PATH

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

ASSETS

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

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

STYLES_BUILD_PATH

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

STYLES

SCSS style definition, { dest: src }

NAME

Unique name to identify template; should form the package name when prefixed with serve-markdown-it-template-.

PUBLIC_PATH

Absolute path to rendered resources folder, ready for serving.

INCLUDE_PATH

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

TEMPLATE

Recommended filename

TEMPLATE

Recommended filename

Functions

getConfig([userConfig])Sermit~Config

Combine the provided & default configurations as-needed.

genImageMarkdown(params)string

Generate a markdown string to display an image at relPath.

genRawSrcMarkdown(params)string

Generate a markdown string to render raw file contents.

renderPageDirectory(templateConfig)Sermit~Renderer

Directory listing renderer.

renderPageFile(templateConfig)Sermit~FileRenderer

Single file renderer.

serve-markdown-it-template-blank

Blank template skeleton for serve-markdown-it, 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 serve-markdown-it-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

ParamTypeDefaultDescription
[userConfig]Sermit~Config{}provided configuration

genImageMarkdown(params) ⇒ string

Generate a markdown string to display an image at relPath.

Kind: global function
Returns: string - md

ParamTypeDescription
paramsobjectparams
params.relPathstringpath relative to content root path.
params.namestringimage alt text.

genRawSrcMarkdown(params) ⇒ string

Generate a markdown string to render raw file contents.

Kind: global function
Returns: string - md

ParamTypeDescription
paramsobjectparams
params.srcPathstringpath to file, resolvable locally via fs

renderPageDirectory(templateConfig) ⇒ Sermit~Renderer

Directory listing renderer.

Kind: global function
Returns: Sermit~Renderer - renderer

ParamTypeDescription
templateConfigConfigtemplate config data.

renderPageFile(templateConfig) ⇒ Sermit~FileRenderer

Single file renderer.

Kind: global function
Returns: Sermit~FileRenderer - renderer

ParamTypeDescription
templateConfigConfigtemplate config data.

Keywords

FAQs

Package last updated on 28 Jun 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc