liveBook · Manning

HTML

As explained in Vanilla Web

The standard markup language for structuring content in web documents.

Every website or web application starts with an HTML document, even when its interface is rendered with Canvas. For content-based interfaces, HTML holds the data and structure; CSS handles design and layout, while JavaScript can add dynamic behavior and interaction. section 3.1

Write HTML for meaning, not appearance. Semantic markup makes it clear which content is a title, navigation, a list, a section, or a supporting detail. Decide on that structure before working out its visual layout. section 3.4

A practical document separates two concerns:

  • The document container supplies metadata, such as a title and description, and can link to stylesheets, icons, and a web app manifest. section 3.1 section 3.3.7
  • The content markup expresses the information and the relationships among its parts. Add CSS for presentation and JavaScript modules where behavior is needed. section 3.1 section 3.4
<head>
  <meta charset="utf-8">
  <title>Coffee Roasters</title>

  <meta name="description" #1
        content="Order specialty coffee beans online. <linearrow />
  Freshly roasted, globally sourced."> #1
  <meta name="keywords"
        content= "coffee,espresso,latte,beans,roast"> #1
  <meta name="author"
        content="Vanilla Web Book Inc."> #1

  <meta property="og:title" #2
        content="Coffee Roasters: Fresh Beans Online"> #2
  <meta property="og:description" #2
        content="Order specialty coffee delivered to <linearrow />
  your door.Freshly roasted, globally sourced."> #2
  <meta property="og:image" #2
        content="https://coffee.example.com/og.jpg"> #2
  <meta property="og:url" #2
        content="https://coffee.example.com/"> #2
  <meta property="og:type" #2
        content="website"> #2
</head>

A coffee storefront’s head shows a character encoding, page title, description, keywords, author, and Open Graph properties. This metadata belongs to the HTML container regardless of how the inner interface is rendered. section 3.3.7

HTML is a living specification maintained by WHATWG, rather than a standard to target by a current version number. Treat HTML, CSS, and JavaScript as separable responsibilities without assuming that every interface needs the same rendering approach or a large framework. section 3.4 section 3.1 section 2.3

How Vanilla Web covers it

How deep it goes
Defines semantic markup and illustrates document metadata, but stops short of detailing individual semantic elements.
Examples
Uses a coffee storefront’s head metadata and an exercise translating an app interface into structural markup.
What it assumes
Introduces the purpose of semantic HTML while assuming familiarity with basic web interface concepts.
What you can do after
Build it from scratch: plan semantic content and an HTML document container before adding presentation or interaction.
How it connects
Connects HTML to CSS, JavaScript, Canvas, web app manifests, and semantic markup.

Also explained in

Compare how 16 books explain HTML →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Vanilla Web. The section links point to the parts of the book it draws on.