What JSX can render

Besides strings, numbers and elements, Jeasx renders many JavaScript values directly, so you rarely have to convert data before putting it into markup. Each sample shows the rendered result and the generated HTML.

Children

Promises
A promise is awaited and its value rendered in place.

Hello from a promise!

<p>Hello from a promise!</p>
Sets and other iterables
Any iterable renders its items, e.g. a Set, a Map or an iterator with helper methods like .map(). No need for Array.from().
<ul><li>apple</li><li>banana</li><li>cherry</li></ul>
Generators
A generator function can be used as a component and yields its items one by one.
  1. 0
  2. 1
  3. 1
  4. 2
  5. 3
  6. 5
  7. 8
  8. 13
<ol><li>0</li><li>1</li><li>1</li><li>2</li><li>3</li><li>5</li><li>8</li><li>13</li></ol>
Dates, URLs and errors
Objects with their own toString render as escaped text.

Created at Fri Oct 30 2026 00:00:00 GMT+0000 (Coordinated Universal Time)
Fetched from https://www.jeasx.dev/?q=%3Cjsx%3E
Failed with Error: Something went wrong

<p>Created at Fri Oct 30 2026 00:00:00 GMT+0000 (Coordinated Universal Time)<br>Fetched from https://www.jeasx.dev/?q=%3Cjsx%3E<br>Failed with Error: Something went wrong</p>
Bytes
A Uint8Array or Buffer renders as UTF-8 text, e.g. a file read with fs.readFile() or the bytes of a fetch() response.
Bytes are decoded as UTF-8 text: ✓ <b>escaped</b>
<pre>Bytes are decoded as UTF-8 text: ✓ &lt;b&gt;escaped&lt;/b&gt;</pre>
BigInts and zero
BigInts render as numbers, and 0 isn't swallowed like in other templating languages.

18446744073709551616 / 0

<p>18446744073709551616 / 0</p>
Nothing at all
null, undefined, booleans, functions and plain objects render nothing.

[]

<p>[]</p>

Attributes

Promise attributes
A promise as attribute value is awaited. All promise attributes of a tag are loaded in parallel.
Avatar loaded asynchronously
<img src="/svg/logo.svg?text=JSX" alt="Avatar loaded asynchronously" width="64" height="64">
Objects and arrays as JSON
Plain objects and arrays are encoded as JSON, e.g. to pass data to client-side scripts.
Inspect me
<div data-config="{&quot;theme&quot;:&quot;dark&quot;,&quot;columns&quot;:3}" data-ids="[1,2,3]">Inspect me</div>
URLs, dates and booleans
Values with their own toString use their string form, true renders the attribute name only.
Download
<a href="https://expo.jeasx.dev/values" data-date="Thu Jan 01 1970 00:00:00 GMT+0000 (Coordinated Universal Time)" download>Download</a>
Skipped values
Functions, null, false and objects without their own string form (e.g. a Set) are skipped, so an event handler never prints its source code.