TinyML is a lightwidth markup language to design web pages.
Traduces TinyML-syntax to HTML-syntax.
🔹 source: string - The TinyML-syntax source to translate to HTML-syntax.
🔹 options: TranslateOptions /* { preserveComments: boolean = true } */ - The options to use when translate.
✅ The HTML.
❌ Throws error.
Input | Output |
---|---|
|
<!DOCTYPE html>
<html lang="en">
<head>
<title>The page title</title>
</head>
<body>
<!-- This is a comment -->
<hr/>
<div class="container">
<h1>My first title</h1>
<p>
Lorem ipsum dolor sit<br>
amet, consectetur
<p>
</div>
</body>
</html> |
Input | Output |
---|---|
|
<body>
<h1>This is a title</h1>
</body> |
Input | Output |
---|---|
|
<body>
<h1>This is a title</h1>
</body> |
Input | Output |
---|---|
|
<!--<body>
<h1>This is a title</h1>
</body>--> |
Input | Output |
---|---|
|
<body>
<!--{<h1>This is a title</h1>}-->
</body> |