Skip to main content

HTM for Python

Project description CircleCI PyPI

A Python version of developit/htm - JSX-like syntax in plain JavaScript Python.


$ pip3 install htm


from htm import htm

def html(tag, props, children):
    return tag, props, children

a = 1
b = {"bar": 100}
c = "span"
d = "world"

  <div foo={a+2} ...{b}>
    <{c}>Hello, {d}!<//>
# ('div', {'foo': 3, 'bar': 100}, [('span', {}, ['Hello,', 'world', '!'])])


Running Tests

$ python3 -m unittest discover -s tests


This library is licensed under the MIT license. See ./LICENSE.

Project details

Download files

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

Files for htm, version 0.1.0
Filename, size File type Python version Upload date Hashes
Filename, size htm-0.1.0-py3-none-any.whl (4.5 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size htm-0.1.0.tar.gz (3.6 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page