# pugvdomify

> Browserify transform to compile pug files into functions returning virtual-dom nodes.

Latest version **0.2.7** (published 2019-06-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install pugvdomify
pnpm add pugvdomify
yarn add pugvdomify
bun add pugvdomify
```

## 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.2.7 |
| Published | 2019-06-18 |
| First published | 2017-10-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 7 |
| Unpacked size | 5.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Gryphon Myers |
| Maintainers | grygabrielphon |
| Keywords | browserify, pug, virtual-dom |

## Links

- npm: https://www.npmjs.com/package/pugvdomify
- Repository: https://github.com/gryphonmyers/pugvdomify
- Homepage: https://github.com/gryphonmyers/pugvdomify#readme
- Issues: https://github.com/gryphonmyers/pugvdomify/issues
- npm.io page: https://npm.io/package/pugvdomify

## Dependencies (7)

- [lodash](https://npm.io/package/lodash.md) ^4.17.4
- [through](https://npm.io/package/through.md) ^2.3.8
- [pug-vdom](https://npm.io/package/pug-vdom.md) ^1.0.6
- [source-map](https://npm.io/package/source-map.md) ^0.5.6
- [virtual-dom](https://npm.io/package/virtual-dom.md) ^2.1.1
- [convert-source-map](https://npm.io/package/convert-source-map.md) ~1.3.0
- [browserify-transform-tools](https://npm.io/package/browserify-transform-tools.md) ^1.6.0

## 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

- 0.2.7 (latest) — 2019-06-18
- 0.1.4 — 2017-10-27

## README

# pugvdomify
Browserify transform to compile pug files into functions returning virtual-dom nodes.

Add it as you would any other browserify transform. Use the global flag if you think there is a possibility you will be requiring external modules that require pug files.
```javascript
var pugvdomify = require('pugvdomify');
var bundler = browserify();
bundler.transform(pugvdomify, {global:true});
bundler.bundle();
//... etc
```
In your modules you can now do
```javascript
var myTemplateFunc = require('./my-pug-file.pug');
var myVNodes = myTemplateFunc({myLocal: "etc"}); //returns an array of virtual-dom nodes
```

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