Lispmark overview/demo

briefing λ syntax λ use λ examples

# briefing


This is a basic overview of a LISP-flavored markup language, uncopyrighted.

The default library contains many HTML tags and useful constructs, and other libraries give examples how a different local could use the software.

Lispmark supports user-definable macros. Its special characters are
(/ the escape with parens tool) , the
(' escape without parens tool) , and its special macros are
(def new-macro {0}) and
(, (do-thing {0}) (' item one) (' item two) (' item three)) .

The def macro is used to define new templates, where the argument they take is either a Lispmark expression or HTML, using at least one formatting field such as {0} and a maximum of two ({0}, {1}) .

The , comma macro is used to map a list of arguments to a template. At this point, only one wildcard may be used with the template. Individual items may be delimited (' using the escape without parens) command.

# syntax


Lispmark syntax is as follows: (cmd arg1 arg2)

Commands are placed at the beginning of a (parens wrapped list) , followed by one or more arguments. For the sake of simplicity, some commands take no arguments, while others take one, very few take two, and only one takes many.

Because this language is meant to replace HTML, one who is familiar with HTML can easily pick it up. Look at these primitive functions which are equivelant to their HTML counterparts:

Many old friends are tagging along. But there's some new ones along for the ride. Look at these:

These are much more user friendly than their markdown equivelants:

# use


This section concerns using Lispmark. All of them include grabbing the parse.py file. import parse and then parse.eval_input (" (your input) ") is used in Python3 .

Parse can be renamed however you want, and the entries in arg1 and arg2 dicts, as well as in the entity array, can be modified freely.

We will also include a demo page that will allow people with our repo downloaded to view loaded entities & commands, and a command line tool to convert .lm inputs to .html outputs.

# examples


Check this out

(def unbold </b>{0}<b>)
(ul (, (li (b {0}))
  (' this is a list of)
  (' bolded text)
  (unbold unbolded text)
  (' wow, magic)))

Also, buttons:

(def button <input type='button' name='{0}' value='{1}'>)
(button Save)


Also, lists:

(def select <select>{0}</select>)
(def opt <option value="{0}">{0}<option>)

(select (, (opt {0})
  (' test)
  (' abc)
  (' 123)))


This document was composed entirely in LispMark.

Hopefully you have access to the source.