← Recipe: package an image and compose visuals

6. Understand the boundaries

luastra/assets · UI.Image · UI.Shape · about 15 minutes
file → manifest → typed reference → URI → semantic node

Each boundary prevents a different class of accidental mismatch and keeps host packaging deterministic.

When to use it

Read this before adding application artwork, thumbnails, or generated visuals.

  • Use UI.Image for admitted PNG, JPEG, WebP, or AVIF detail; SVG is not admitted by this candidate contract.
  • Use UI.Shape for supported scalable geometry; do not make a Shape act like a button.
  • Give meaningful images and shapes concise labels. Use label="" only when the visual adds no information.
  • width and height reserve stable layout space; fit controls scaling inside that frame.
  • Asset IDs are stable application identifiers, while source paths are project implementation details.

Complete inventory

View all pages in Recipe: package an image and compose visuals
← Previous: 5. Check and run