Skip to main content

A tool for generating table-based recipe descriptions.

Project description

Recipe Grid is a collection of standalone utilities and also a Python library for describing recipes in a tabular form, as illustrated by the following (rather tasty) recipe below for tiffin:

docs/source/_static/tiffin_example.png

These recipes have several advantages over traditional recipe descriptions:

  • Recipes are typically more concise.

  • Ingredients and method are shown together so no need to cross-reference between the two.

  • Parts of the method are never “hidden” in an ingredients list (e.g. ‘1 onion, finely chopped’)

  • Opportunities to reorder steps or do them in parallel (or not!) are easy to spot while still providing a suggested order.

Recipes are described in Markdown files using a convenient to write recipe description language. For example, the recipe above was generated from the following Markdown:

Tiffin
======

A delicious, chocolatey treat.

    6 tsp of cocoa powder
    2 tbsp of golden syrup
    1/2 cup of butter
    1/2 cup of sugar
    16oz of digestives
    200g of chocolate

    cover(
        mix(
            heat until bubbling (cocoa powder, golden syrup, butter, sugar),
            crush(digestives)
        ),
        melt(chocolate)
    )

Getting Started

You can install recipe grid from PyPI using:

$ pip install recipe_grid

Then head over to the tutorial or jump straight into the main documentation.

Development

Development dependencies, and an editable install can be setup using:

$ pip install -e .
$ pip install -r requirements-test.txt

Tests can be run using:

$ pytest

Other pre-commit hooks can be run using:

$ pre-commit run -a

And build the documentation using:

$ pip install -r requirements-docs.txt
$ make -C docs html

What about version 1?

Recipe Grid 2 is a rewrite/reimagining of its predecessor which ended up being one of those quick hacks which went on to live for a great many years. Recipe Grid 2’s recipe format is not quite backward compatible but is largely a superset of the old format and upgrading existing recipes is not an arduous task.

Recipe Grid 2 has many additional features while retaining a very similar recipe description language. Key improvements include:

  • More consistent recipe syntax and data model

  • Recipes live within Markdown files

  • Supports Directed Acyclic Graph (DAG) recipes; not just trees

  • Can scale more than just ingredient quantities in a recipe

  • Better error messages

  • Fewer foot-guns

  • Linter included to spot common errors

  • Better HTML rendering
    • Improved readability

    • Includes mouseover unit conversions

    • Native serving counts and applied scaling more clearly indicated

  • Better static sites
    • Links to alternative scaling of recipes

    • Browse without selecting a scale

    • Clearer navigation

    • Supports multiple levels of hierarchy

    • Supports custom messages on home and category pages

    • Much faster and more robust static site generator

  • Extensive documentation

  • Large test suite

  • (Limited) Python API for parsing and inspecting recipes

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

recipe_grid-2.1.1.tar.gz (184.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

recipe_grid-2.1.1-py3-none-any.whl (90.6 kB view details)

Uploaded Python 3

File details

Details for the file recipe_grid-2.1.1.tar.gz.

File metadata

  • Download URL: recipe_grid-2.1.1.tar.gz
  • Upload date:
  • Size: 184.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for recipe_grid-2.1.1.tar.gz
Algorithm Hash digest
SHA256 f6ea2d6ab134daa326b955ee99506418ba2738e719ac41d695e7a670128fa841
MD5 45aedecade11b80764ed6f846e7ea10e
BLAKE2b-256 ec2a7d4be71f4a1d95b68910d2caf3ed180c306b02806eabc83e872d0fcc87cd

See more details on using hashes here.

File details

Details for the file recipe_grid-2.1.1-py3-none-any.whl.

File metadata

  • Download URL: recipe_grid-2.1.1-py3-none-any.whl
  • Upload date:
  • Size: 90.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for recipe_grid-2.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d5c2e19010db9975bb4311396092fe576a7b25baad48beee96b681f128a8f54f
MD5 f2948139efdd62a3e8323787ceaf01cd
BLAKE2b-256 864645c057f81e70e5fcd756f3ccc8d471c8b3e0e7dc7bec4ce96abd781d5c8e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page