# yo-yoify

> Transform yo-yo or bel template strings into pure and fast document calls

Latest version **4.3.0** (published 2018-01-02) · MIT license · 0 weekly downloads

## Install

```sh
npm install yo-yoify
pnpm add yo-yoify
yarn add yo-yoify
bun add yo-yoify
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 4.3.0 |
| Published | 2018-01-02 |
| First published | 2016-03-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 110 |
| Author | Kyle Robinson Young |
| Maintainers | toddself, bret, yoshuawuyts, shama |
| Keywords | bel, yo-yo, choo, elements, browserify, plugin, transform |

## Links

- npm: https://www.npmjs.com/package/yo-yoify
- Repository: https://github.com/shama/yo-yoify
- Issues: https://github.com/shama/yo-yoify/issues
- npm.io page: https://npm.io/package/yo-yoify

## Dependencies (6)

- [acorn](https://npm.io/package/acorn.md) ^5.0.0
- [hyperx](https://npm.io/package/hyperx.md) ^2.0.3
- [on-load](https://npm.io/package/on-load.md) ^3.2.0
- [through2](https://npm.io/package/through2.md) ^2.0.1
- [transform-ast](https://npm.io/package/transform-ast.md) ^2.2.1
- [convert-source-map](https://npm.io/package/convert-source-map.md) ^1.5.1

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 4.3.0 (latest) — 2018-01-02
- 4.2.0 — 2017-11-21
- 4.1.0 — 2017-11-12
- 4.0.1 — 2017-11-12
- 4.0.0 — 2017-09-29
- 3.7.3 — 2017-05-02
- 3.7.2 — 2017-04-28
- 3.7.1 — 2017-04-28
- 3.7.0 — 2017-03-28
- 3.6.0 — 2017-03-28
- 3.5.0 — 2016-11-18
- 3.4.2 — 2016-11-16
- 3.4.1 — 2016-08-03
- 3.4.0 — 2016-07-30
- 3.3.0 — 2016-07-13
- … 13 more at https://npm.io/package/yo-yoify/versions

## README

# yo-yoify

[![NPM version][npm-image]][npm-url]
[![build status][travis-image]][travis-url]
[![build status][appveyor-image]][appveyor-url]
[![Downloads][downloads-image]][downloads-url]
[![js-standard-style][standard-image]][standard-url]

Transform [choo][choo-url], [yo-yo][yo-yo-url], or [bel][bel-url] template
strings into pure and fast document calls.

## install

```shell
npm install yo-yoify --save-dev
```

## usage

When using Browserify, use as a global transform:

```shell
browserify entry.js -g yo-yoify -o bundle.js
```

## how this works

`yo-yo` and `bel`, without this transform, pass template literals to `hyperx`.
`hyperx` then parses and extracts the tags. `bel` then turns those tags into
calls to `document.createElement()`.

When using this transform, your template literals:

```js
var msg = 'hello!'
var element = yo`<div>${msg}</div>`
```

Transform into direct calls to the `document`:

```js
var msg = 'hello!'
var element = (function () {
  var bel0 = document.createElement("div")
  appendChild(bel0, [arguments[0]])
  return bel0
}(msg))
```

Which means, way better performance and compatibility with older browsers.

# see also

- [babel-plugin-yo-yoify](https://www.npmjs.com/package/babel-plugin-yo-yoify) — yo-yoify as a Babel transform, works with any build setup that supports Babel

# license
(c) 2016 Kyle Robinson Young. MIT License

[choo-url]: https://github.com/yoshuawuyts/choo
[yo-yo-url]: https://github.com/maxogden/yo-yo
[bel-url]: https://github.com/shama/bel
[npm-image]: https://img.shields.io/npm/v/yo-yoify.svg?style=flat-square
[npm-url]: https://npmjs.org/package/yo-yoify
[travis-image]: https://img.shields.io/travis/shama/yo-yoify/master.svg?style=flat-square
[travis-url]: https://travis-ci.org/shama/yo-yoify
[appveyor-image]: https://img.shields.io/appveyor/ci/shama/yo-yoify/master.svg
[appveyor-url]: https://ci.appveyor.com/project/shama/yo-yoify
[downloads-image]: http://img.shields.io/npm/dm/vel.svg?style=flat-square
[downloads-url]: https://npmjs.org/package/yo-yoify
[standard-image]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square
[standard-url]: https://github.com/feross/standard

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