🍳 Foodlang

Web Publishing (Schema.org)

Publish any Foodlang recipe to the web as Schema.org Recipe JSON-LD — the structured data Google, Pinterest, and recipe aggregators read for rich results.

Compile

foodlang compile examples/simple-latte.food.yaml --target schema-org
{
  "@context": "https://schema.org",
  "@type": "Recipe",
  "name": "Simple Latte",
  "description": "A basic hot latte made with espresso, steamed milk, and foam.",
  "recipeYield": "1 serving",
  "keywords": "coffee, latte",
  "recipeIngredient": [
    "18 g coffee grounds",
    "40 mL water",
    "220 mL milk",
    "40 mL milk foam"
  ],
  "recipeInstructions": [
    "Grind 18 g of coffee for espresso.",
    "Brew a double espresso using about 40 mL of water.",
    "Steam 220 mL of milk until silky and hot.",
    "Pour steamed milk into espresso and top with foam."
  ]
}

Drop it into a page

<script type="application/ld+json">
  /* output of: foodlang compile recipe.food.yaml --target schema-org */
</script>

Fidelity

The schema-org target is executable — the output is a directly usable artifact you can ship to production with no further processing.