Pixel UI/Delight/Receipt printer

Receipt printer

A little thermal printer that prints your content, line by line.

<piix-receipt>DOM + canvas

Piixpal Store

#0042 · 19 Oct 2026


Pixel pal (kitty)

Extra pats


Total

Thanks for shopping!

When it scrolls into view the printer wakes up, its light blinks and the paper feeds out one line at a time, each one swept on by the print head. Headings print as big pixel titles, <hr> as a dashed rule, and anything with data-price gets a dotted leader out to its price. When it is done, TEAR rips it off along a zigzag. Your markup stays real the whole time: readable, selectable and searchable.

Installation

<!-- once, anywhere on the page: every component -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.6/piixpal.min.js"></script>

Usage

<piix-receipt width="300px">
  <h3>Piixpal Store</h3>
  <p data-center>#0042 · 19 Oct 2026</p>
  <hr>
  <p data-price="$12.00">Pixel pal (kitty)</p>
  <p data-price="$4.00">Extra pats</p>
  <hr>
  <p data-price="$16.00" data-total>Total</p>
  <p data-center>Thanks for shopping!</p>
</piix-receipt>

Examples

Your year, printed

Anything goes on the paper: here, a year-end summary.

2026 Wrapped

Commits

Pals shipped

Pats given


See you in 2027

Print on demand

With start="manual" it waits for print().

Order #77

Pixel tee

Total

Checkout

API reference

AttributeWhat it doesDefault
widththe paper width320px
speedlines a second7
startview: print when it scrolls into view. manual: wait for print()view
soundmake sounds even without <piix-chiptune>; off keeps it silent–
data-priceon a line inside: a dotted leader out to this price–
data-totalon a line inside: bold and a little bigger–
data-centeron a line inside: centred–

Events

EventWhen
printedthe last line is out
tearit was torn off

Methods

MethodWhat it does
print()print it (again)
tear()tear it off
reset()back into the printer

Accessibility