# templace

> progressive content loader

Latest version **0.1.1** (published 2018-05-17) · CC0-1.0 license · 0 weekly downloads

## Install

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

## 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.1.1 |
| Published | 2018-05-17 |
| First published | 2018-05-17 |
| Weekly downloads | 0 |
| License | CC0-1.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 10.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Ryan Van Etten |
| Maintainers | ryanve |
| Keywords | dom, performance, progressive, enhancement, template, loading, loader |

## Links

- npm: https://www.npmjs.com/package/templace
- Repository: https://github.com/ryanve/templace
- Issues: https://github.com/ryanve/templace/issues
- npm.io page: https://npm.io/package/templace

## Alternatives

- [babylon](https://npm.io/package/babylon.md) — 5.1M weekly downloads
- [csscolorparser](https://npm.io/package/csscolorparser.md) — 3.7M weekly downloads
- [expr-eval-fork](https://npm.io/package/expr-eval-fork.md) — 1.5M weekly downloads
- [@leeoniya/ufuzzy](https://npm.io/package/@leeoniya/ufuzzy.md) — 247.7K weekly downloads
- [xml-parser](https://npm.io/package/xml-parser.md) — 78.4K weekly downloads

## Recent versions

- 0.1.1 (latest) — 2018-05-17
- 0.1.0 — 2018-05-17

## README

# templace
Progressively load template content via JavaScript. Useful for wrapping low-priority heavy content like `iframe` embeds such to load after initial page load and only when JavaScript is enabled

```
npm install templace
```

## usage

```html
<template data-templace>
  <iframe src="..."></iframe>
</template>
```

#### Include `script` late in page for best performance benefits

```html
<script src="templace.js" async defer></script>
```

#### Templacements happen automagically when the script loads or anytime you invoke the export

```js
templace()
```

#### Normalize `template` CSS for browsers without support

```css
template {
  display: none;
}
```

## status
It's a simple minimum viable package with more granular features in consideration

## demo
https://ryanve.github.io/templace/

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