# coffee-html

> generate HTML in CoffeeScript

Latest version **0.4.2** (published 2014-05-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install coffee-html
pnpm add coffee-html
yarn add coffee-html
bun add coffee-html
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.2 |
| Published | 2014-05-25 |
| First published | 2014-05-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 8 |
| Author | jiyinyiyong |
| Maintainers | jiyinyiyong |
| Keywords | html, coffee-script |

## Links

- npm: https://www.npmjs.com/package/coffee-html
- Repository: https://github.com/jiyinyiyong/coffee-html
- Issues: https://github.com/jiyinyiyong/coffee-html/issues
- npm.io page: https://npm.io/package/coffee-html

## Alternatives

- [@tsparticles/shape-image](https://npm.io/package/@tsparticles/shape-image.md) — 303.7K weekly downloads
- [@tsparticles/shape-line](https://npm.io/package/@tsparticles/shape-line.md) — 233.7K weekly downloads
- [stringify-attributes](https://npm.io/package/stringify-attributes.md) — 58.6K weekly downloads
- [mobile-drag-drop](https://npm.io/package/mobile-drag-drop.md) — 46.3K weekly downloads
- [@comunica/actor-rdf-parse-html](https://npm.io/package/@comunica/actor-rdf-parse-html.md) — 29.2K weekly downloads

## Recent versions

- 0.4.2 (latest) — 2014-05-25
- 0.4.1 — 2014-05-25
- 0.4.0 — 2014-05-25

## README

Coffee-HTML: generate HTML in CoffeeScript
------

### Usage

You can install Coffee-HTML with NPM:

```bash
npm install coffee-html
```

Its syntax looks like:

```coffee
{html} = require 'coffee-html'

data =
  rose: 'flower'
  lilyturf: 'plant'

page = html ->
  @div class: 'demo',
    @div id: 'demo',
      for name, type of data
        @div class: 'content',
          @text "#{name}: #{type}"
    if data.others?
      @div class: 'more', (@text data.others)

page # => generated HTML here
```

This package only supports tags that defined in the source code.
Customized tags are not supported.

### Changelog

* `0.4.1`
  * Refactor code from my early years
  * Remove `__proto__`

* `0.4.0`
  * Previously named Liliturf, renamed to Coffee-HTML

### Early ideas:

A Gist: https://gist.github.com/2498711

### License

MIT

---
_Source: https://npm.io/package/coffee-html · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
