MarkupL

From Esolang
Jump to navigation Jump to search

MarkupL is an alternative universe version of the HTML language. Created by Tom Three

Syntax

This section is still a work in progress. It may be changed in the future.

MarkupL syntax

MarkupL doesn't have a paragraph tag. Which isn't that big of a deal since you can literally just add a end of line tag (or |el) to make a new line:

­ 1: "a"|el

translated into html:

<p>a</p>

don't forget to add another virtic (|) if you need to add another string next to an end of line:

­ 1: "a"|el|"b"

translated into html:

<p>a</p>b

and if you don't, then:

­ 1: "a"|el"b" /will just show "a" without emitting a newline/

and if you need to add an id to that string. Use the id> operator

­ 1: id="smth">"hi"

translated into html:

<p id="smth">hi</p>

MarkupL also has fields

MarkupL add-ons

Stuley:

­ 1: <style>...|}

Interactive Script:

­ 1: <behave>...|}


Examples

Hello, world!

­ 1: "Hello, world!"|el

translated into html:

<p>Hello, world!</p>

Cat program

­ 1: <field type="multi" id="i">input</field><button text="submit" pushaction="main{}">|el|id="o">""
­ 2: <behave>make main{}<i=take("i")|set("o".ML,i)>|}

translated into html:

<script>function main(){i=document.getElementById("i").value;document.getElementById("o").innerHTML=i}</script>
<textarea id="i" placeholder="input"></textarea><button onclick="main()">submit</button><br>
<textarea id="o" placeholder="output" readonly></textarea>