What's a Markup Language
Nathan Kamgang
Have you heard the phrase “X is a markup language” where X could be HTML, Markdown, LaTeX, or XML? But what exactly is a markup language? Let’s do a thought experiment. Imagine that you’re a busy author who writes books but don’t want to have to format the book yourself. You don’t want to worry about the table of contents, the page numbers, the footnotes, the bold words… So you engage a publisher that will format your book properly.
Because you’re an old-school writer, you wrote it on paper, annotated with a red pen the places in your book where you need special formatting. You highlighted certain words that should be formatted as bold. Others that should be titles, some italicized… Those annotations represent your markup. They should later be interpreted by your publisher in order to produce the final printed book. Likewise, a mark up uses tags that will be passed on to an interpreter to produce a final result.
HTML has an interpreter in every browser that knows what to do with all the HTML tags you wrote. One markup language can, of course, have many different interpreters. The interpreter is like a machine that will take your markup and output a result.
Nothing limits us to only formatting. You can pass any kind of information to the interpreter. The XML markup language is used in projects to give information about the dependencies a program should fetch.
Futhermore, one markup language can possess many different interpreter. They will take the same annotated file but give different outputs.