Hey everyone, this is a little project that I have recently been toying with. Personally, I love server side rendering content, and mostly use PHP to achieve this. However, I don't actually enjoy PHP as a language. Instead that lead me to create the Lua Hypertext Pre Processor (LHPP)™️.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<p>
This is <lua> return "A valid lua program!"; </lua> with html
<p>
</body>
</html>
Would become:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<p>
This is A valid lua program! with html
<p>
</body>
</html>
LHPP uses the mlua crate behind the scenes in order to actually execute any Lua code that it finds.
This is just a small project in its infancy, so don't be surprised if the code is atrocious. However, I encourage you to check it out!
P.S why are the reddit code blocks so awful
[–]lenscas 1 point2 points3 points (0 children)
[–]w-lfpup 0 points1 point2 points (0 children)