0.1.8 • Published 3 years ago

esi-processor v0.1.8

Weekly downloads
33
License
MIT
Repository
github
Last release
3 years ago

esi-processor

node npm

A processor for processing ESI tags in html documents. Currently supporting esi:include, esi:remove, esi:comment, <!--esi -->, esi:choose and esi:vars.

Installation

npm install esi-processor

Usage

const esi = require('esi-processor').ESI;

const processed = await esi(html, [options]);

Options

You can use the following options:

BaseUrl

Add a base url to be used on relative esi:includes

Headers

Add custom HTTP headers for remote esi:includes e.g. { 'X-Custom-Header': 'x-custom-value' }

IgnoreEsiChooseTags

Ignore the esi:choose tags, only returning a comment

XmlMode

Use xmlMode (defaults to true). This option is passed to htmlparser2.

Verbose

Print extended log to the console.

0.1.8

3 years ago

0.1.7

3 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

5 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago