modules/text/lorem.zzm

text-lorem-0.0.1 documentation

Package

Name
text-lorem
Version
0.0.1
Uploaded
2026-05-13 17:33:33
Dependencies
Metadata
zuzu-distribution.json
Archive
Download .tar.gz

NAME

text/lorem - Generate lorem ipsum style placeholder text.

SYNOPSIS

  from text/lorem import lorem, lorem_markdown;

  say( lorem( { paragraphs: 3 } ) );
  say( lorem( {
      paragraphs: 5,
      format: "html",
      headings: true,
      lists: true,
  } ) );
  say( lorem_markdown( 4, true, true ) );

DESCRIPTION

This pure-Zuzu module generates placeholder prose in plain text, HTML, or Markdown. The paragraph count controls the number of content blocks. When list generation is enabled, a bullet list containing four to eight items counts as one paragraph. Random headings may be inserted before content blocks and do not count towards the paragraph total.

EXPORTED FUNCTIONS

  • lorem(Dict options?)

    Generate text using options. Supported keys are paragraphs, format, headings, and lists. The format value may be text, html, or markdown.

  • lorem_text(Number paragraphs := 3, Boolean headings := false, Boolean lists := false)
  • lorem_html(Number paragraphs := 3, Boolean headings := false, Boolean lists := false)
  • lorem_markdown(Number paragraphs := 3, Boolean headings := false, Boolean lists := false)

COPYRIGHT AND LICENCE

text/lorem is copyright Toby Inkster.

It is free software; you may redistribute it and/or modify it under the terms of either the Artistic License 1.0 or the GNU General Public License version 2.