1.4.0 • Published 2 years ago

@totemstan/blog v1.4.0

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

BLOG

BLOG converts TOTEM markdown to html.

Manage

npm install @totemstan/blog		# Install
npm run start [ ? | $ | ...]	# Unit test
npm run verminor				# Roll minor version
npm run vermajor				# Roll major version
npm run redoc					# Regen documentation

Usage

Acquire and optionally configure BLOG:

const BLOG = require("blog").config({
	key: value, 						// set key
	"key.key": value, 					// indexed set
	"key.key.": value					// indexed append
});

where configuration keys follow ENUMS deep copy conventions

Program Reference

BLOG

Converts TOTEM markdown to html. This module documented in accordance with jsdoc.

Requires: module:enums, module:mathjax-node

BLOG.digits

Precision to show values in JSON || #DOC || TEX OP= JSON || #DOC || TEX expansions

Kind: static property of BLOG

BLOG.subs

TeX substitutions.

Kind: static property of BLOG

BLOG.:=(lhs, rhs, ctx) ⇒ string

Expands LHS := RHS TeX patterns using toEqn

Kind: static method of BLOG

ParamType
lhsstring
rhsstring
ctxobject

BLOG.toEqn(pre, lhs, rhs, ctx) ⇒ string

Expands JSON || #DOC || TEX OP= JSON || #DOC || TEX TeX patterns

Kind: static method of BLOG

ParamTypeDescription
prestringprefix
lhsstringlhs of pattern
rhsstringrhs of pattern
ctxobjectblogging context

BLOG~blog(ctx, cb)

Short form of blogify.

Kind: inner method of BLOG

ParamTypeDescription
ctxObjectinitial blogging context
cbfunctioncallback accepting the resulting html

BLOG~blogify(ctx, src, rec, cb)

Expands markdown:

$ VIEW { SRC ? w=WIDTH & h=HEIGHT & x=KEY$INDEX & y=KEY$INDEX ... }  
$ { JS }   
[ LINK ] ( URL )  
$ $ inline TeX $ $ || n$ $ break TeX $ $ || a$ $ AsciiMath $ $ || m$ $ MathML $ $
TeX := TeX || #VAR || VAR#KEY#KEY...
# SECTION  
ESCAPE || $with || $for || $if:\\n \\t BLOCK \\n

to html.

Kind: inner method of BLOG

ParamTypeDescription
ctxObjectinitial blogging context
srcStringdefault source path
recObjectsource record
cbfunctioncallback accepting the resulting html

Contacting, Contributing, Following

Feel free to

License

MIT


© 2012 ACMESDS