ScratchData LogoScratchData
Back to TheTally's profile

LHTML code compiler

THTheTally•Created November 16, 2023
LHTML code compiler
0
1
14 views
View on Scratch

Instructions

My first attempt of making an html transpiler. the "L" is lite (Lite HyperText Markup Language) JS VERSION: https://replit.com/@YandeMC/Lite-compiler-js PYTHON VERSOIN : https://replit.com/@YandeMC/lite-compiler-pyhton some examples: empty div: {div} or {div } image: {img[src="img.png" alt="img"]} simple header with paragraph {h1 header}{p stuff} classes {div[."class1 class2"]content of div} ids: {div[#"id1 id2"]content of div} escaping characters: {p use \\ to escape out a character, like \{ \} but putting a \\in the mid\dle\ of con\t\e\nt do\es noth\ing} css: {div[."blue"]{h1 header}{p paragraph}}{style .blue \{ background-color: blue;\}}

Description

some stuff i might do but idk if i can: self closing tags edge cases COMMON MISTAKES: not putting a space before content: {divcontent} putting a space before attributes: {div [."class]hi} doing this: div{hi} or {[div]} forgetting to close elements: {div hello how to fix your mistakes: dont be dumb make sure you place stuff where it goes at the end, if the list "in element" has something in it, you didnt close an element.

Project Details

Project ID925625877
CreatedNovember 16, 2023
Last ModifiedNovember 29, 2023
SharedNovember 16, 2023
Visibilityvisible
CommentsAllowed