linkifier

It converts HTML headers (h1, h2, h3, h4, h5 & h6) into links.

Usage no npm install needed!

<script type="module">
  import linkifier from 'https://cdn.skypack.dev/linkifier';
</script>

README

linkifier


linkifier

Last version Build Status Dependency status Dev Dependencies Status NPM Status Donate

It converts HTML tags (like h1, h2, h3, h4, h5 & h6) into links.

Install

$ npm install linkifier --save

Usage

Vanilla

linkifier(document.getElementsByTagName('h2'))

jQuery

$('h2').linkifier()

API

linkifier(, [opts])

element

Required
Type: object

Collection of Node Elements to wrap into links.

opts

class

Type: string
Default: 'deep-link'

A class to attach with the link wrapper.

License

MIT © Kiko Beats